Add configurable Docker hostname#356
Conversation
|
|
@erasche sure, there is a lot to do for IE's. I'm a little bit confused what this has to do with this PR. I think to most of these (known) problems To which boilerplate are you referring? If there is any configuration that holds true for all IE's we should probably move this into galaxy.ini? I'm also fine with an interactive_environment.ini/xml where it makes sense. But this option is IE specific, imho. I would like to be able to have one VM for IPython containers and another one for RStudio ... |
|
The proxy works out of the box for this? That is fantastic - I demand a gold star or some sort of blue ribbon :). Can we modify the docker build command to use the host argument - so it doesn't need to be replicated twice in the ini file? |
|
🌟!!! It's working here on our Freiburg Galaxy Server, with the mentioned disadvantages from Eric, but it's working :) We could indeed use the Docker hostname in the build command. |
|
@bgruening I say we allow specfying a docker host then instead of proxy hostname - and pull the destination hostname from that? How does that sound? I am still trying to get away from the IEs and deployers building command-line pieces. |
|
Ok, sounds good. If not set, we simply do not set the |
|
I'm +0 on this right now...if you aren't running ANYTHING other than docker on your glxdk1, then it's fine as-is (though I'd really like to see SSL client cert options added, I am NOT running docker containers on a remote host with no authentication).
No, not hidden. I'm just slightly worried this supports an impractical deployment method. You're essentially requiring that glxdk1 have free ports in the range used, otherwise images could get launched, the glxdk1 would start+fail them, and the user would have a bad experience. This is further "bad" if you start ramping up usage, and two docker containers randomly get spawned with the same port, because the host says it's free. Two IPython containers, started at different times, could generate the same port #. The host would say it's free, it's not on the docker host.
yeah, agreed. There's a lot to be done here, from fixing the proxy, to better methods for deploying/running these jobs.
And if I were to deploy them, I might want all of my docker images on a single VM. We should inherit a global IE configuration, and override it with IE specific settings. It would be nice if the following were standard, and then IE overridable:
So... really all of them. Our IE specific config files would be reduced to: [docker]
image = bgruening/docker-ipython-notebook:devstealth edit: password_auth defaults to false, as does apache_urls and ssl with the nodejs proxy |
|
@bgruening I can make the configuration options more generic in another PR. I don't want to stop your progress...just worried about
|
|
@jmchilton a Docker hostname can have the following form: |
|
@bgruening Okay - fair point - I guess we need two variables. Though you called this So I think this should be merge with changing this to hostname - and then a follow up pull request should be issued at some point by someone (maybe me) that adds the host binding support and SSL options - all of which should be taken care of at the framework level instead of exposing this to the IEs and in the command line tweak flag. To address more of @erasche concerns - I wonder if the config/galaxy.ini should be able to override defaults for any of these. Something like |
|
Also @erasche - it seems like this does address the ports thing right? I think un-shown in @bgruening example is that he is adding a |
|
I am 👍 on this - @erasche are convinced yet it is a step in the right direction? |
|
@jmchilton I made the name more explicit. |
|
👍, let's get this merged.
Sure, that would be fine, I'm pretty ambivalent where a "parent" IE configuration would go. Maybe we stick it in a file next to galaxy.ini? It's already pretty full...
Hmm, maybe I mis-communicated. Say you have the following situation:
There's nothing in the commit to address that. The only thing you could do is to check the session map/proxy and interact with it to get a list of used ports on the remote host, which would help save you.
Okay, sure, fair enough. I guess the tl;dr was that I wanted to see more shared configuration |
Add configurable Docker hostname
|
@erasche Arg - you are right about the ports. I was thinking docker was picking them - I forgot we were. |
|
@jmchilton after GCC I'll start planning infrastructure to support this, since it's definitely a priority for me. If we want any traction in enterprise-y environments, a separate docker host will be important. |
|
Added a point 8, thought about it a bit more and had an unpleasant realisation:
this'll definitely happen because the proxy has auth'd the user for the specified remote host/port, if it's ipython they'll likely see a "page not found" and click the button and may be able to get back to the IE that someone else is using? Provisioned with the other user's API key/history IDs/etc. |
|
If you were expiring routes in the nodejs session map quickly enough, I'd say let's place a unique constraint on that. However, I think routes are fairly long lived and you just take the most recent one (if memory serves) |
This PR will add a new configuration option to Interactive Environments -
docker_host. With this option you can specify a different docker hostname. This is very useful if you only have a Docker client on your Galaxy host and your Docker daemon is running on somewhere else.If this is ok, I will add it to RStudio as well.
Questionable point is if it's ok to initialize
load_deploy_config()in the__init__.ping @jmchilton and @erasche