Last active
July 11, 2017 14:18
-
-
Save amekusa/2ac6a3e7f4a93649a53fb28940935e7d to your computer and use it in GitHub Desktop.
Let's Encrypt Auto Renewal
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
| [Unit] | |
| Description=Let's Encrypt renewal | |
| [Service] | |
| Type=oneshot | |
| ExecStart=/usr/bin/certbot renew --pre-hook "/usr/bin/systemctl stop nginx.service" --post-hook "/usr/bin/systemctl start nginx.service" --quiet --agree-tos | |
| ExecStartPost=/bin/systemctl reload nginx.service |
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
| [Unit] | |
| Description=Daily renewal of Let's Encrypt's certificates | |
| [Timer] | |
| OnCalendar=daily | |
| RandomizedDelaySec=1day | |
| Persistent=true | |
| [Install] | |
| WantedBy=timers.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment