Use Docker Behind Proxy on Windows 8
The other day I had to install Docker at work, aka behind a corporate proxy (on Windows 8).
While the docker installer is stand-alone and all is good, dealing with the VM is a different matter… The problem popped up when I tried to create a Django image and
pip install failed miserably. To get around, you need to create a docker machine:
docker-machine create -d virtualbox \
--engine-env HTTP_PROXY=http://example.com:8080 \
--engine-env HTTPS_PROXY=https://example.com:8080 \
--engine-env NO_PROXY=example2.com \
You also need to pass in the proxy as a build argument to
docker build --build-arg https_proxy="http://example.com:8080"
You can also pass the build argument to
docker-compose but, in this case, you need to specify the services.
A little experiment: If you find this post and ad below useful, please check the ad out :-)