Scheduled Task (renewal)
$ sudo crontab -e
# Lets encrypt twice daily
0 7,19 * * * certbot -q renew
Script that reads le.txt and requests certificates for each domain
$ nano le.sh && chmod +x le.sh
DOMAINS=$(paste -s -d, le.txt)
sudo letsencrypt certonly --webroot -w /var/www/html -d $DOMAINS
sudo service nginx reload
Note: Recently certbot changed from seperating each domain with -d
to comma seperated.
List of Domains (one per line, add to the end)
$ nano le.txt
vandragt.com
www.vandragt.com