Docker proxy settings

Here’s a quick way to configure docker to work with proxy. Keep in mind that this only works if you are using boot2docker or a docker-machine. This generally applies to Windows or Mac operating systems.

Create a new docker-machine with proxy:

Edit user, password, example.com and port variables with appropriate values. Also, make sure you have correct domains excluded within NO_PROXY variable.

To change proxy credentials later on, edit  /var/lib/boot2docker/profile and set HTTP_PROXY and HTTPS_PROXY environment variables.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.