|
1 år sedan | |
---|---|---|
cron | 4 år sedan | |
CHANGELOG | 4 år sedan | |
DSTROOTCAX3.txt | 5 år sedan | |
LICENSE | 5 år sedan | |
README.md | 4 år sedan | |
apache-le-alias.conf | 5 år sedan | |
apache-le-proxy.conf | 5 år sedan | |
gen-cert.sh | 1 år sedan | |
gen-unifi-cert.sh | 1 år sedan | |
get-letsencrypt.sh | 5 år sedan | |
nginx-le-root.conf | 4 år sedan |
Public Git URL: https://source.sosdg.org/brielle/lets-encrypt-scripts
By: Brielle Bruns bruns@2mbit.com
These are various scripts to make LetsEncrypt easier to use.
gen-cert.sh - Main script to make it easy to generate LE certs for domain(s)
gen-unifi-cert.sh - Script to add LE cert to a Unifi controller
DSTROOTCAX3.txt - Root CA cert for use with the gen-unifi-cert.sh script (now optional and unneeded as the cert is embedded)
apache-le-alias.conf - Use with apache for LE well-known alias config
apache-le-proxy.conf - Use with apache for LE well-known proxy config
Do initial cert generation (if using webroot, see script contents for more methods of authentication):
gen-cert.sh -e email@address.com -d somedomain.com -d otherdomain.com -r /var/www/letsencrypt-root/
Copy cron/renew-ssl-weekly.sh to /etc/cron.weekly, edit as appropriate
Run:
chmod 750 /etc/cron.weekly/renew-ssl-weekly.sh
Script will now run weekly and renew the certificate if necessary ( < 30 days remain). Don’t forget to add any necessary file copies/symlinks/service restarts as needed once the scripts are updated.
Do initial cert generation:
gen-unifi-cert.sh -e email@address.com -d unifi.somedomain.com -d unifi.someotherdomain.com
Put in /etc/cron.weekly/renew-unifi-ssl if everything works okay:
/path/to/script/gen-unifi-cert.sh -r -d unifi.somedomain.com -d unifi.someotherdomain.com
Script will now run weekly and renew the certificate if necessary ( < 30 days remain) and restart unifi only if cert has been renewed.