My galaxy and NGINX are running strong. How do you merge these together? How do you add nginx to galaxy?
We have a wiki page about setting it all up here: https://wiki.galaxyproject.org/Admin/Config/nginxProxy
Please ask if you have any questions. We use nginx for usegalaxy.org and it works great.
Dan, I do appreciate your concern..
I must have read through that tutorial 100+ times.lol. I appreciate the good documentation but when it comes to merging the two together(NGINX & Galaxy), Its not specific at all.
The documentation never states how to "simply" add nginx to galaxy, nor does it guide you to verify the working environment. Any suggestions?
I'm not sure what you're asking. Can you be more specific which step you're having trouble with?
There are two important files, galaxy.ini and nginx.conf. At the moment, I simply want to configure Basic proxy request/serve static content using nginx. My galaxy.ini and nginx is configured properly and is running. When i run the command "curl -I 127.0.0.1" I get this..
HTTP/1.1 302 Found Server: nginx/1.9.12 Date: Mon, 21 Mar 2016 21:43:52 GMT Content-Type: text/html Connection: keep-alive x-frame-options: SAMEORIGIN Set-Cookie: galaxysession=ID#
Is that good?
My question is... Do I need to add any nginx parameters to the galaxy.ini file to let my galaxy server know to use nginx? Or does my nginx.conf simply use uptream galaxy_app {server localhost:8080 }??
As documented in your galaxy.ini, there are various advanced options that can be enabled to support extra nginx features, but it isn't a requirement to use any of these for the most basic configuration.
Once you've set up nginx with an upstream galaxy server and the routes as detailed in that wiki page I linked before, you should be good to go.
An easy way to test this is just to hit the nginx server location with a browser. I assume Galaxy is running on port 8080 (or some other port), and nginx is running on 80. When you navigate to 127.0.0.1 in your browser, what happens?
True about the extra features. Ok I will look into that...to get a better understanding of the routes handling.
Currently my galaxy browser shows/run using this address: http://hpcNode01:8081/
How do you use this link? http://galaxy_app
This is working thus far:
####Galaxy Configurations
upstream galaxy_app {
# for TCP setups, point these to your backend servers
server hpcNode01:8081;
}
proxy_next_upstream off;
server {
client_max_body_size 10G;
location / {
proxy_pass **http://galaxy_app;**
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
location ~ ^/plugins/visualizations/(?<vis_name>.+?)/static/(?<static_file>.*?)$ {
alias /sge/galaxy_dist/config/plugins/visualizations/$vis_name/static/$static_file;
}
}
}
I actually switched to Apache, which works fine. Haven't tried to get nginx running since. Sorry.