Last active
July 17, 2016 18:53
-
-
Save kevinSuttle/52f06db5a6ea353bbb38 to your computer and use it in GitHub Desktop.
Ghost + Nginx + letsencrypt + keybase.io + Digital Ocean + DNSimple
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /etc/nginx/sites-enabled/ghost | |
server { | |
root /usr/share/nginx/html; | |
index index.html index.htm; | |
listen 443 ssl; | |
server_name kevinsuttle.com www.kevinsuttle.com; | |
ssl_certificate /etc/letsencrypt/live/kevinsuttle.com/fullchain.pem; | |
ssl_certificate_key /etc/letsencrypt/live/kevinsuttle.com/privkey.pem; | |
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; | |
ssl_prefer_server_ciphers on; | |
ssl_ciphers 'EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH'; | |
location ~ /.well-known { | |
allow all; | |
root /var/www/; | |
} | |
location / { | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header HOST $http_host; | |
proxy_set_header X-NginX-Proxy true; | |
proxy_pass http://127.0.0.1:2368; | |
proxy_redirect off; | |
root /var/www/; | |
} | |
location /.well-known/ { | |
root /var/www/; | |
} | |
} | |
server { | |
listen 80; | |
server_name kevinsuttle.com; | |
return 301 https://$host$request_uri; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Why is this block needed?
Isn't this taken care of earlier at Line 16-19?
Line 30-32?
location /.well-known/ {
root /var/www/;
}