Network unreachable when trying to install in Docker

Hi,
it’s my first Topic that im writing, so please be gentle :smiley:

I’m trying to install Certbot on my local Docker instace. The installation works partly.
Certbot spits out a lot of “Network unreachable” errors, so that i cannot finish the installation.

I tried installing without having to provide an E-Mail with following command:
docker run -it --rm --name certbot -p 80:80 -v "C:\ProgramData\Docker\volumes\etc\letsencrypt:/etc/letsencrypt" -v "C:\ProgramData\Docker\volumes\lib\letsencrypt:/var/lib/letsencrypt" certbot/certbot --register-unsafely-without-email certonly
Result was the same.

My domain is:
none
I ran this command:
docker run -it --rm --name certbot -p 80:80 -p 443:443 -v "C:\ProgramData\Docker\volumes\etc\letsencrypt:/etc/letsencrypt" -v "C:\ProgramData\Docker\volumes\lib\letsencrypt:/var/lib/letsencrypt" certbot/certbot certonly
It produced this output:
How would you like to authenticate with the ACME CA? - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 1: Spin up a temporary webserver (standalone) 2: Place files in webroot directory (webroot) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Select the appropriate number [1-2] then [enter] (press ‘c’ to cancel): 1 Plugins selected: Authenticator standalone, Installer None Enter email address (used for urgent renewal and security notices) (Enter ‘c’ to cancel): An unexpected error occurred: Traceback (most recent call last): File “/usr/local/lib/python3.8/site-packages/urllib3/connection.py”, line 156, in _new_conn conn = connection.create_connection( File “/usr/local/lib/python3.8/site-packages/urllib3/util/connection.py”, line 84, in create_connection raise err File “/usr/local/lib/python3.8/site-packages/urllib3/util/connection.py”, line 74, in create_connection sock.connect(sa) OSError: [Errno 101] Network unreachable During handling of the above exception, another exception occurred: Traceback (most recent call last): File “/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py”, line 665, in urlopen httplib_response = self._make_request( File “/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py”, line 376, in _make_request self._validate_conn(conn) File “/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py”, line 994, in _validate_conn conn.connect() File “/usr/local/lib/python3.8/site-packages/urllib3/connection.py”, line 300, in connect conn = self._new_conn() File “/usr/local/lib/python3.8/site-packages/urllib3/connection.py”, line 168, in _new_conn raise NewConnectionError( urllib3.exceptions.NewConnectionError: <urllib3.connection.VerifiedHTTPSConnection object at 0x7f2ea7942610>: Failed to establish a new connection: [Errno 101] Network unreachable During handling of the above exception, another exception occurred: Traceback (most recent call last): File “/usr/local/lib/python3.8/site-packages/requests/adapters.py”, line 439, in send resp = conn.urlopen( File “/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py”, line 719, in urlopen retries = retries.increment( File “/usr/local/lib/python3.8/site-packages/urllib3/util/retry.py”, line 436, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host=‘acme-v02.api.letsencrypt.org’, port=443): Max retries exceeded with url: /directory (Caused by NewConnectionError(’<urllib3.connection.VerifiedHTTPSConnection object at 0x7f2ea7942610>: Failed to establish a new connection: [Errno 101] Network unreachable’)) During handling of the above exception, another exception occurred: Traceback (most recent call last): File “/opt/certbot/src/acme/acme/client.py”, line 1088, in _send_request response = self.session.request(method, url, *args, **kwargs) File “/usr/local/lib/python3.8/site-packages/requests/sessions.py”, line 533, in request resp = self.send(prep, **send_kwargs) File “/usr/local/lib/python3.8/site-packages/requests/sessions.py”, line 646, in send r = adapter.send(request, **kwargs) File “/usr/local/lib/python3.8/site-packages/requests/adapters.py”, line 516, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host=‘acme-v02.api.letsencrypt.org’, port=443): Max retries exceeded with url: /directory (Caused by NewConnectionError(’<urllib3.connection.VerifiedHTTPSConnection object at 0x7f2ea7942610>: Failed to establish a new connection: [Errno 101] Network unreachable’)) During handling of the above exception, another exception occurred: ValueError: Requesting acme-v02.api.letsencrypt.org/directory: Network unreachable Please see the logfiles in /var/log/letsencrypt for more details.
My web server is (include version):
none
The operating system my web server runs on is (include version):
Using Docker Desktop (Version 2.2.0.3) on Windows 10 Enterprise (Version 1809)
My hosting provider, if applicable, is:
none
I can login to a root shell on my machine (yes or no, or I don’t know):
no
I’m using a control panel to manage my site (no, or provide the name and version of the control panel):
no
The version of my client is (e.g. output of certbot --version or certbot-auto --version if you’re using Certbot):
I think the latest Version available with Docker. See Command.

Hi @sndp24152

a worldwide visible, unique domain name is required if you want to create a certificate. So that can’t work.

But that’s not your Network unreachable error. No idea how to fix that - Windows + Docker.

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