Keywords: General - AWS - How to - Secure Connections (SSL/HTTPS)
Description:
Hello,
I generated an ssl certificate for my domain.
The latter ends on December 1, 2019.
In the crontab I add this line to renew it:
0 0 2 2 * * * /opt/bitnami/letsencrypt/scripts/renew-DOMAIN.sh 2> /dev/null
The content of my file is as follows:
sudo /opt/bitnami/ctlscript.sh stop apache
sudo /opt/bitnami/letsencrypt/lego --tls --email="EMAIL" --domains="DOMAIN" --path="/opt/bitnami/letsencrypt" renew --days 90
sudo /opt/bitnami/ctlscript.sh start apache
On the second of each month, the certificate will try to be renewed.
On December 2, the certificate will therefore be renewed.
The next deadline will be December 1 + 90 days, i.e. February 29, 2020. And the certificate will be renewed the next day, on March 1st.
Then the next deadline will be March 1st + 90 days i.e. May 30th 2020.
So the day of May 31st will not be covered by an SSL certificate because the renewal will only be done the next day, June 1st.
How to ensure that the automatic renewal of the certificate is ALWAYS done the day after the certificate expires?
Thank you !!