certbot systemd stuff¶
certbot-renewal.service¶
The Conflicts and friends was intended to restart the service when the cert changes, but it did not work as intended. Still looking into it (whenever I have time, energy, and remember about it).
[Unit]
Description=Certbot Renewal Check
Documentation=https://eff.org
After=network.target
#Conflicts=elastic-agent.service
#OnSuccess=elastic-agent.service
#OnFailure=elastic-agent.service
[Service]
Type=oneshot
ExecStart=/opt/certbot/bin/python /opt/certbot/bin/certbot renew --quiet --agree-tos
certbot-renewal.timer¶
[Unit]
Description=Twice Daily Timer for Certbot Renewal
[Timer]
OnCalendar=*-*-* 00,12:00:00
RandomizedDelaySec=43200
Persistent=true
[Install]
WantedBy=timers.target