Skip to content

Instantly share code, notes, and snippets.

@kevinSuttle
Last active July 17, 2016 18:53
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save kevinSuttle/52f06db5a6ea353bbb38 to your computer and use it in GitHub Desktop.
Save kevinSuttle/52f06db5a6ea353bbb38 to your computer and use it in GitHub Desktop.
Ghost + Nginx + letsencrypt + keybase.io + Digital Ocean + DNSimple
# /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;
}
@blueelvis
Copy link

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/;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment