RancherOS behind a corporate proxy.

867 views
Skip to first unread message

Thomas Attree

unread,
May 6, 2015, 8:58:13 AM5/6/15
to ranc...@googlegroups.com
This may be rather obvious but I've not been successful in setting this up.

How do I define a proxy server to use for user docker to use when contacting public repositories?

I've attempted to set environment variables like I would normally but I think I'm missing something. Has anybody else done this?

Cheers!

Darren S

unread,
May 7, 2015, 7:28:43 PM5/7/15
to ranc...@googlegroups.com, tom.a...@gmail.com
To setup a proxy with docker that requires setting the HTTP_PROXY environment variable.  In the latest release dev build of RancherOS (v0.3.1-rc2), this can be set through a configuration file.  You can edit /var/lib/rancher/conf/docker and put the following in the file

export HTTP_PROXY=http://example.com

Upon restart or restarting the user docker (sudo system-docker restart docker) the environment variable will take effect.  There are two issues with this approach though.

1) We can create that file during from cloud-init, so it is not possible to do this on first boot
2) This only impacts user docker and not system docker

I believe we should add a feature to RancherOS to make this easier.  We will try to get this into RancherOS v0.3.1.

Darren

Alexandre Pophal

unread,
Jun 23, 2015, 11:17:16 AM6/23/15
to ranc...@googlegroups.com, tom.a...@gmail.com
I am using an authenticated proxy and when I try this, I get an error saying unknown port tcp/mypassword. Using https_proxy=https://myuser:mypassword@proxy:port format

Looks like this format, although a common for many Linux´s flavors, is not supported. So, what to do when you need to authenticate against the proxy server?

Thanks

Ivan Mikushin

unread,
Jul 8, 2015, 5:03:14 AM7/8/15
to ranc...@googlegroups.com, tom.a...@gmail.com
I believe, the best option in this case is a transparent proxy
Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages