How can I use a Let's Encrypt SSL certificate?
Edit your site and flip the Let's Encrypt switch!
Please read step 6 "Configure your HTTPS options" under Adding Sites for more information.
Automatic provisioning of LE certificates can take anywhere from 5 minutes to an hour or longer, depending on volume of certificates waiting to be issued, DNS propagation for your domain, the capacity of the Let's Encrypt service itself, and other factors.
Create a site by following the instructions here: Building a Site.
The rest of this procedure assumes that you're using a PHP or static application for your site, and uses the following values which you will need to change to match your specific user, app, and domain:
myuseris the shell user name
myappis the application name
mydomain.comis the domain name
Log into your server via SSH with the shell user that you created in step 1 above.
Execute the following commands in your SSH session to create your certificate, changing the first three commands to match your email address, domains, and app name:
export EMAILADDRfirstname.lastname@example.org export DOMAINS=mydomain.com,www.mydomain.com export WEBROOT=$HOME/apps/myapp export CERTBOTROOT=$HOME/certbot mkdir ~/certbot certbot register --agree-tos --no-eff-email -m $EMAILADDR \ --config-dir $CERTBOTROOT \ --work-dir $CERTBOTROOT \ --logs-dir $CERTBOTROOT certbot certonly -a webroot -w $WEBROOT \ --config-dir $CERTBOTROOT \ --work-dir $CERTBOTROOT \ --logs-dir $CERTBOTROOT \ -d $DOMAINS
If you are manually generating a certificate for the first time, then the commands should run with no further input.
If you repeat the commands for a certificate that you've previously generated manually then you'll be presented with options to keep or renew the existing certificate. If this happens then choose the option that you want and proceed to the next step.
Follow our instructions for adding a certificate to the panel, using the contents of the following files for the certificate details:
- Intermediate Certificate:
You can use the
catcommand in your SSH session to get the contents of the files, eg
cat /home/myuser/certbot/live/mydomain.com/cert.pem, which you can then copy from your terminal and paste into the control panel form for your new certificate.
Finally, assign the certificate to your site.
🎉 Congratulations - you now have a website encrypted with a manually-generated free Let's Encrypt SSL certificate!