Skip to main content

Configure Let's Encrypt SSL on CentOS 6

Get the LetsEncrypt certbot-auto script.

curl -o /usr/local/sbin/certbot-auto

Make it executable.

chmod a+x /usr/local/sbin/certbot-auto

Generate a SSL certificate using DNS verification.

sudo /usr/local/sbin/certbot-auto certonly \
--manual \
--agree-tos \
--preferred-challenges=dns \
--server \
--email [email protected] \

Generated certificated will be available under /etc/letsencrypt/live/


Setup a cron job to run the renewal command everyday at midnight. The renewal will be executed only if there are 30 days less from the expiration date.

# Setting up crontab
crontab -e

# Append the below line to the end of crontab
0 0 * * * /usr/local/sbin/certbot-auto renew --renew-hook "/sbin/service nginx reload" --quiet --agree-tos


  1. How to setup Nginx to use SSL with Let's Encrypt