Created
December 11, 2016 11:04
-
-
Save katopz/28340c56898895ecdc44ffc2e2e04612 to your computer and use it in GitHub Desktop.
reccers
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
#!/bin/sh | |
# https://github.com/certbot/certbot/issues/1833 | |
export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games | |
# Ensure script is call | |
echo $(date)'|Renewal' >> /var/log/letsencrypt/daily.log | |
# This script renews all the Let's Encrypt certificates with a validity < 30 days | |
if ! /opt/letsencrypt/letsencrypt-auto renew > /var/log/letsencrypt/renew.log 2>&1 ; then | |
echo Automated renewal failed: | |
cat /var/log/letsencrypt/renew.log | |
exit 1 | |
fi | |
# Restart to take effect | |
nginx -t && nginx -s reload |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment