강동현
Builds for 1 pipeline failed in 1 minute 15 seconds

http를 https로 리다이렉트하도록 설정

...@@ -18,5 +18,6 @@ services: ...@@ -18,5 +18,6 @@ services:
18 restart: unless-stopped 18 restart: unless-stopped
19 ports: 19 ports:
20 - "443:443" 20 - "443:443"
21 + - "80:80"
21 volumes: 22 volumes:
22 - /etc/letsencrypt:/etc/letsencrypt 23 - /etc/letsencrypt:/etc/letsencrypt
......
...@@ -20,5 +20,6 @@ COPY web/default.conf /etc/nginx/conf.d/default.conf ...@@ -20,5 +20,6 @@ COPY web/default.conf /etc/nginx/conf.d/default.conf
20 COPY --from=build /usr/web/build /usr/web/build 20 COPY --from=build /usr/web/build /usr/web/build
21 21
22 EXPOSE 443 22 EXPOSE 443
23 +EXPOSE 80
23 24
24 CMD ["nginx", "-g", "daemon off;"] 25 CMD ["nginx", "-g", "daemon off;"]
......
1 server { 1 server {
2 + listen 80;
3 + return 301 https://$host$request_uri;
4 +}
5 +
6 +server {
2 listen 443 ssl default_server; 7 listen 443 ssl default_server;
3 server_name 2020105578.oss2021.tk; 8 server_name 2020105578.oss2021.tk;
4 9
......