This is a quick reference guide to Add the free ssl certificate letsencrypt to your site , if you don't like to go deep into details .
First create letsEncrypt certificate following these commands :
To check certificate validation :
To check certificate dates :
OR
add to cron job
add this line:
How to renew the certificate :
First create letsEncrypt certificate following these commands :
sudo a2ensite default-ssl
sudo add-apt-repository ppa:certbot/certbot
sudo apt-get update
sudo apt-get install python-certbot-apache
sudo certbot --apache -d example.com
To check certificate validation :
https://www.ssllabs.com/ssltest/analyze.html?d=example.com&latest
To check certificate dates :
echo | openssl s_client -connect yourdomain.tld:443 -servername yourdomain.tld 2>/dev/null | openssl x509 -noout -dates
OR
openssl x509 -noout -dates -in /etc/letsencrypt/live/yourdomain.tld/cert.pem
add to cron job
crontab -e
add this line:
0 0 1,15 * * /usr/bin/certbot renew --quiet
How to renew the certificate :
certbot renew
No comments:
Post a Comment