So far as I can tell, certbot works in the following way:
example.com
.example.com
and ready to prove it owns that domain.First, ensure that your DNS A record, such as example.com
, resolves to
the IP address your server is using. This needs to be an internet accessible
IP address, not an internal RFC-1918 address.
This guide assumes you're using Ubuntu Server.
add-apt-repository ppa:certbot/certbot
apt-get update
apt-get install certbot
Set the site
variable here to your DNS entry which will point to this server.
site="example.com"
certbot certonly --standalone --preferred-challenges http -d $site
You can find the certificates as files on your server.
> cd /etc/letsencrypt/live/$site
README cert.pem chain.pem fullchain.pem privkey.pem
Copy these certs to your web service and use them like any other cert.
Note that if you want to use these certs for HAProxy, you need to combine
cert.pem
and privkey.pem
into a single file.
cat cert.pem privkey.pem > haproxy-$site.pem