Failure to Connect to

Hey everyone. I've been trying to debug the following problem for awhile now to no avail.
Any help would be appreciated. For context, this is running within a docker container.

My domain is:

I ran this command:

  certbot certonly --test-cert --webroot -w /var/www/certbot \
    $staging_arg \
    $email_arg \
    $domain_args \
    --rsa-key-size $rsa_key_size \
    --agree-tos \
    --force-renewal" certbot

It produced this output:

An unexpected error occurred:
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='', port=443): Max retries exceeded with url: /directory (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f4890ecaf40>: Failed to establish a new connection: [Errno -3] Try again'))

My web server is (include version):

The operating system my web server runs on is (include version): Occurs on both Debian 10 and Manjaro

My hosting provider, if applicable, is: Azure and Local

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

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

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you're using Certbot): Occurs on v1.27 and v1.26

1 Like

@lestaff this is the third one I see. Any opinions?

@mkingsley can you show me the output of this?

curl -vvv


It seems that from within the contaienr I can't resolve the DNS address:

Output of: curl -vvv

* Could not resolve host:
* Closing connection 0
curl: (6) Could not resolve host:

staging did just switch over to only allowing TLS1.2 but Could not resolve host seems more like a dns or IP routing problem.


Agreed. I think the timing with server maintenance is fishy, but probably not the cause.

I've since tried adding to my container's DNS options and it is still unable to resolve. The Docker host is having no issues resolving.

Outbound DNS being blocked by firewall rules?
[check both systems]

Try something simpler like:
curl -I
[that's the IP for]


Ping on is successful, I can also curl -I successfully.

However when I try to reach via curl -I I am getting:

curl -I
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (56) Recv failure: Connection reset by peer

I am able to successfully ping

Okay. I think I have resolved the issue.
In docker it seems that my container was not binding properly to my host network stack.

It is safe to say that this isn't a LetsEncrypt problem.

Thanks for all the help!


Glad you found the problem.

Just noting the "reset by peer" is expected for that request. The acme endpoint requires HTTPS://


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.