Failing to get new Cert (DOCKER)

My domain is:

I ran this command:
docker run -it -v "/home/bprudence/.certs/" -v "/var/log/letsencrypt:/var/log/letsencrypt" certbot/dns-route53 certonly -n --dns-route53 --agree-tos --email --domains * --server

It produced this output:
Saving debug log to /var/log/letsencrypt/letsencrypt.log
An unexpected error occurred:
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='', port=443): Max retries exc
eeded with url: /directory (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f58d0c74400>:
Failed to establish a new connection: [Errno -3] Try again'))
Ask for help or search for solutions at See the logfile /var/log/letsencrypt/letsencr
ypt.log or re-run Certbot with -v for more details.

My web server is (include version):

The operating system my web server runs on is (include version):

My hosting provider, if applicable, is:

I can login to a root shell on my machine (yes or no, or I don't know):

I'm using a control panel to manage my site (no, or provide the name and version of the control panel):

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you're using Certbot):
certbot 1.28.0

It looks like your container can't communicate via outgoing https, or perhaps the DNS lookup fails.

1 Like

Turns out I needed to tell Docker to use proper DNS. Getting silly now. Thanks for making me check outside of Certbot!

1 Like