letsencrypt renew automatically with cron

Every three months i must renew my ssl certificates for my subdomains. Because of a lot of subdomains and also different domains it costs a lot of time.

So here’s the solution to renew the letsencrypt certificates automatically with cron:

At the first of every month letsencrypt checks to renew the certificate.

nano /etc/crontab

01 0    1 * *   root    systemctl stop nginx && /root/letsencrypt/letsencrypt-auto renew && systemctl start nginx

(Insert your letsencrypt path)

nano /etc/letsencrypt/webroot.ini

# webroot.ini general config file

rsa-key-size = 4096

email = info@mattionline.de

text = True
agree-tos = True
renew-by-default = True

# https://certbot.eff.org/docs/using.html
# standalone or webfoot (what you prefer and your configs are set to)
authenticator = standalone

Kommentar verfassen

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert

Nach oben scrollen