I\'m trying to run docker on windows (OS: Microsoft Windows 10 Pro 64bit, Docker ver: 18.09.0, build 4d60db4), by following the hello-world instruction here. Then I got thi
We had this problem on Linux behind a corporate proxy after upgrading Docker from version 17 to the latest 19 (currently 19.03.5).
# docker run hello-world
Unable to find image 'hello-world:latest' locally
docker: Error response from daemon: Get https://registry-1.docker.io/v2/: proxyconnect tcp: dial tcp: lookup http on 1.2.3.4:53: server misbehaving.
1.2.3.4
is the IP of our DNS server, which itself worked fine - I could resolve different hosts, also registry-1.docker.io
from Docker.
The problem was how we set the proxy globally in /etc/systemd/system/docker.service.d/http-proxy.conf
. Since its an MS AD user, it contains the username in the format of domain\user
like this:
[Service]
Environment="HTTP_PROXY=http://domain\user:password@proxyserver.internal:80"
Same thing for HTTPS_PROXY
. While this worked on version 17, it doesn't seem to work with 19. Now the backslash seems to cause problems. Just remove it like this:
[Service]
Environment="HTTP_PROXY=http://user:password@proxyserver.internal:80"
I'm not sure if this changed with version 19 or already in version 18, since we skipped 18. But if you upgrade to 18 or 19 this is a thing i'd check. There is a simply way to figure it out:
docker info | grep -i proxy
If you see censored credentials like this
HTTP Proxy: http://xxxxx:xxxxx@proxyserver.internal:80
HTTPS Proxy: http://xxxxx:xxxxx@proxyserver.internal:80
then you're not affected of this issue. But if you see the plain credentials, Docker can't parse them because of the backslash or maybe other special characters included in your env variable.