Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save kurtis318/9b7d63f2d2c86f3801c11d9642ba68d8 to your computer and use it in GitHub Desktop.
Save kurtis318/9b7d63f2d2c86f3801c11d9642ba68d8 to your computer and use it in GitHub Desktop.
Installing LetsEncrypt’s free SSL and auto-renewing
I have an OwnCloud server on the Internet. I needed a valid SSL certificate. I found a web site that told me how to register and install a free SSL certifiacate from LetsEncrypt. Today, I got an email saying my SSL certificate would expire in 9 days.
The following web site has instructions on how to do this for a Linux server on Amazon. It will also work for me based on the instructions.
https://nouveauframework.org/blog/installing-letsencrypts-free-ssl-amazon-linux/
Steps to renew are as follows:
sudo su
cd /root
wget https://dl.eff.org/certbot-auto
chmod +x certbot-auto
crontab -e
# Add the following line to crontab file:
0 1,13 * * * /root/certbot-auto renew
# Save file using <esc>:qw
Here is what the output looked like when running command interactively:
/root/certbot-auto renew
Creating virtual environment...
Installing Python packages...
Installation succeeded.
Saving debug log to /var/log/letsencrypt/letsencrypt.log
-------------------------------------------------------------------------------
Processing /etc/letsencrypt/renewal/jakedog.duckdns.org.conf
-------------------------------------------------------------------------------
Cert is due for renewal, auto-renewing...
Plugins selected: Authenticator apache, Installer apache
Renewing an existing certificate
Performing the following challenges:
tls-sni-01 challenge for jakedog.duckdns.org
Waiting for verification...
Cleaning up challenges
-------------------------------------------------------------------------------
new certificate deployed with reload of apache server; fullchain is
/etc/letsencrypt/live/jakedog.duckdns.org/fullchain.pem
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
Congratulations, all renewals succeeded. The following certs have been renewed:
/etc/letsencrypt/live/jakedog.duckdns.org/fullchain.pem (success)
-------------------------------------------------------------------------------
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment