Comment out portion of nginx.conf added by Certbot

This commit is contained in:
wiz 2019-12-01 11:41:25 +09:00
parent e439407a74
commit b13e819933
No known key found for this signature in database
GPG Key ID: A394E332255A6173

View File

@ -37,25 +37,25 @@ http {
listen [::]:80; listen [::]:80;
server_name example.com; server_name example.com;
if ($host = example.com) { # if ($host = example.com) {
return 301 https://$host$request_uri; # return 301 https://$host$request_uri;
} # managed by Certbot # } # managed by Certbot
#
return 404; # managed by Certbot # return 404; # managed by Certbot
} # }
#
server { # server {
listen [::]:443 ssl http2; # managed by Certbot # listen [::]:443 ssl http2; # managed by Certbot
listen 443 ssl http2; # managed by Certbot # listen 443 ssl http2; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/example.com/fullchain.pem; # managed by Certbot # ssl_certificate /etc/letsencrypt/live/example.com/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/example.com/privkey.pem; # managed by Certbot # ssl_certificate_key /etc/letsencrypt/live/example.com/privkey.pem; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot # include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot # ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
#
root /var/www/html; # server_name example.com; # managed by Certbot
index index.html; index index.html;
server_name example.com; # managed by Certbot root /var/www/html;
location / { location / {
try_files $uri $uri/ /index.html =404; try_files $uri $uri/ /index.html =404;