Created
September 17, 2017 18:50
-
-
Save mrunkel/20a7f74b6be5e4938caef6d0cff5671c to your computer and use it in GitHub Desktop.
This file contains 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
everyone saying that Caddy made it simple for automated LE; I agree, but also, it's not that difficult to setup with NGINX: | |
Edit /var/nginx/ssl_common.conf | |
ssl_certificate /etc/letsencrypt/live/<site>/fullchain.pem; | |
ssl_certificate_key /etc/letsencrypt/live/<site>/privkey.pem; | |
location ^~ /.well-known/acme-challenge/ { | |
default_type "text/plain"; | |
allow all; | |
root /var/www/example; | |
auth_basic off; | |
} | |
Edit crontab, add: | |
30 2 * * 1 /bin/certbot -a webroot --webroot-path=/var/www/example renew --renew-hook "systemctl reload nginx" | |
Make the cert | |
mkdir -p /var/www/example | |
certbot certonly --webroot -w /var/www/example/ -d www.example.com | |
In your NGINX HTTPS server blocks add: | |
include ssl_common.conf | |
That should be i |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment