The Docker Version being used is
$ docker version
time=“2018-01-29T15:03:54+05:30” level=info msg="Unable to use system certificate pool: crypto/x509: system root pool is not available on Windows"
Client:
Version: 17.03.0-ce
API version: 1.26
Go version: go1.7.5
Git commit: 60ccb22
Built: Thu Mar 2 01:11:00 2017
OS/Arch: windows/amd64
Server:
Version: 17.04.0-ce
API version: 1.28 (minimum version 1.12)
Go version: go1.7.5
Git commit: 4845c56
Built: Wed Apr 5 18:45:47 2017
OS/Arch: linux/amd64
Experimental: false
The laptop has Windows 10 installed.
CNTLM proxy has been set to run on 192.168.99.1:3128.
The docker machine has been configured to use this proxy by setting the value of HostOptions.EngineOptions.Env in config.json of the docker machine. The docker pull command is able to get the images from the hub.
The alpine image was downloaded and this was run using the command
docker run -it alpine /bin/sh
This also works.
Now environment variables http_proxy and https_proxy were set to use the proxy 192.168.99.1:3128 as indicated earlier.
ping to 192.168.99.1 works fine.
/ # ping 192.168.99.1
PING 192.168.99.1 (192.168.99.1): 56 data bytes
64 bytes from 192.168.99.1: seq=0 ttl=127 time=1.139 ms
64 bytes from 192.168.99.1: seq=1 ttl=127 time=1.086 ms
^C
— 192.168.99.1 ping statistics —
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 1.086/1.112/1.139 ms
When wget is invoked a socket is established to 192.168.99.1:3168 from the docker-machine, but in the container it hangs showing connecting to 192.168.99.1. (The netstat -an in the windows command line shows that the connection has been established).
What is the mistake? And how to rectify it?