Uh oh!
There was an error while loading. Please reload this page.
optionally add docker host to proxy excludes in env command - #631
optionally add docker host to proxy excludes in env command#631databus23 wants to merge 2 commits into
Conversation
ehazlett
commented
Feb 26, 2015
@SvenDowideit your thoughts? |
nathanleclaire
commented
Feb 27, 2015
I haven't had time to review this but @databus23 I'd suggest you please break this down into several smaller functions- that's a lot of stuff for just one function to do. |
databus23
commented
Feb 27, 2015
@nathanleclaire Sure. I agree its quite a lot of code for one method and can be structured better. But before I spend more time on this can we agree that there is a problem and a solution would be considered for a merge? |
ehazlett
commented
Feb 27, 2015
@databus23 yes i think this would be beneficial |
nathanleclaire
commented
Feb 27, 2015
@databus23 Yes, I am in favor of the feature. I have a question: If the user wants to connect to a remote instance, they will actually want to use the proxy to enable internet connectivity, no? How is that case handled? Also, side note for @ehazlett : this logic is really getting hairy enough that we should eventually move to using a text/template to generate these commands instead. |
ehazlett
commented
Feb 27, 2015
+1 for |
databus23
commented
Feb 27, 2015
@nathanleclaire Yes, for remote instances the user might actually need the proxy to get to the instance. Thats why I implemented it as an optional boolean flag |
nathanleclaire
commented
Feb 27, 2015
@databus23 Ah, of course - the flag. I'm sorry, I'm being thick due to this recent flurry of activity. At any rate, if you break that into a few smaller functions and especially if you add some unit tests (for these new functions - don't feel responsible for |
nathanleclaire
commented
Feb 27, 2015
Some guidance on how to structure the subroutines: please pass in the values from |
databus23
commented
Feb 27, 2015
@nathanleclaire I'm not sure I understand your guidance, could you maybe elaborate? |
nathanleclaire
commented
Mar 3, 2015
Most important thing is to parse what you need out of |
nathanleclaire
commented
Sep 11, 2015
@databus23 Any followup on this? |
databus23
commented
Sep 15, 2015
Not yet. But I'm still interested in seeing this in machine. #1676 is kind of a duplicate of this issue btw. |
fcb75cf to
5da8457Comparedatabus23
commented
Sep 15, 2015
I updates the pull request against latest master. This will add the docker host ip to the This fixes #1676 which has ben labeled Thoughts? |
nathanleclaire
commented
Sep 15, 2015
Nice, I'll make sure to take a look. |
5da8457 to
12f1a78Comparedatabus23
commented
Sep 19, 2015
Rebased on top of current master. Circles is still in a moody. |
153fed8 to
0745d93Comparedatabus23
commented
Sep 22, 2015
Rebased on current master. All green. |
nathanleclaire
commented
Sep 23, 2015
This is rad! Code looks pretty good. Could I get you to add a section to |
This optinal flag will add the docker host to the no_proxy environement variable. This is useful for local providers (e.g. virtualbox, fusion) in environments where an http_proxy is set and docker by default tries to connect to the ip via the proxy. Signed-off-by: Fabian Ruff <fabian@progra.de>
0745d93 to
44cb170Compare44cb170 to
686e94eComparedatabus23
commented
Sep 23, 2015
@nathanleclaire documentation added. |
Signed-off-by: Fabian Ruff <fabian@progra.de>
686e94e to
75885c3Comparenathanleclaire
commented
Sep 23, 2015
Alright, sorry about this but I've just merged the rather large |
nathanleclaire
commented
Sep 23, 2015
Update: I have successfully rebased so you won't need to worry about that. I will make a PR on your repo which you can merge (as well as add a few integration tests for this feature), and then we can merge this upstream! |
databus23
commented
Sep 23, 2015
@nathanleclaire you beat me to it by minutes. :) |
nathanleclaire
commented
Sep 23, 2015
:D |
nathanleclaire
commented
Sep 23, 2015
Carried it in my own PR to make things a little easier 👍 |
This adds a
--no-proxyflag to thedocker-machine envcommand.When set it will take care of adding (and removing) the docker host to/from the NO_PROXY environment variable.
This helps using docker-machine with docker >=1.5 with local vm providers (e.g. fusion, virtualbox) in coporate networks where an http proxy is required for internet connectivity.
Since version 1.5 the docker client picks up the HTTP_PROXY environment variable when connecting to the docker daemon. This does not work well for the local vm use case. In that case the docker host is inside a local virtual network only reachable from the workstation itself.
@ehazlett This pull request also has the intention to illicit some feedback from you regarding this PR boot2docker/boot2docker-cli#345 :)