Hi,
I want to have the Galaxy production server in the intranet behind a Nginx server that is connected to the internet.
I didn’t find any information about that topic apart from a few unanswered questions.
Possible or taboo?
Best,
Samuel
Definitely possible and should not be different from any other reverse proxy setup. Are there any specific issues you’ve encountered ?
Thanks for the interest.
I got a white page (not an error), but its source code contains mainly javascript that shows nothing.
Here is the current basic configuration within debian
server {
listen 80;
location / {
return 301 http://the_institute_URL;
}
location /galaxy/ {
include proxy_params;
proxy_pass http://10.36.10.49:8080/;
}
}
The proxy_params file contains
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
It would be good if you could come up with a solution.
Best.
NB: currently I am trying to a testing Galaxy instance, ie a simple instance manually launched with sh run.sh. I don’t know if this could make a difference.
I see you’re serving galaxy at the prefix /galaxy here. Do you have the same mapping on the galaxy side?
You’ll need to set the mount
and manage-script-name
options in your galaxy.yml configuration file. The other thing that would be useful to see is the full network request log from your browser’s developer tools – that would help validate that it’s requesting the javascript client files from the wrong address.
Good point, the serving point in the testing instance is /, not /galaxy.
I am going to update the testing instance as I want to keep the prefix.
Thanks a lot.
Here I am trying to define the prefix of an instance launched by “run.sh”. I didn’t find any clear “prefix” nor “URL” option, but Dannon’s advice works perfectly. So I succeeded in getting the galaxy interface at localhost:8080/galaxy/ while launching “run.sh”. Then, I updated the configuration of the proxy server to point it to the new URL with the galaxy prefix.
Here is my final configuration to set /galaxy at the proxy server and at the galaxy instance (whose ip address is 10.36.10.49).
I changed the following lines in config.yml as pointed by Dannon.
#module: galaxy.webapps.galaxy.buildapp:uwsgi_app()
mount: /galaxy=galaxy.webapps.galaxy.buildapp:uwsgi_app()
manage-script-name: true
nginx config
server {
listen 80;
location / {
return 301 http://the_institute_URL;
}
location /galaxy/ {
include proxy_params;
proxy_pass http://10.36.10.49:8080/galaxy/;
}
}
During testing, I used the static part of Galaxy for checking that the communication is OK between servers. If I ask for /galaxy/static/welcome.html, I got the static “middle” page of the interface. So it sounds as if it’s OK to serve static content.
I didn’t run any analysis yet, only the interface. More on that tomorrow.
Thanks guys.
Tested with concurrent. OK.
To be noticed: while the galaxy instance is linked to /galaxy as stated in galaxy.yml, it still serves /. I mean onthe intranet server, not on the internet proxy.