Add a configurable option to galaxy.ini that would allow only admins to log in into galaxy. This could be used for instance when Galaxy has just received an upgrade and validation is required on tools inside Galaxy to see if everything is still working 100% perfectly. By locking out regular users, it would allow administrators to test it and get everything ready.
We achieved the same effect with some fancy proxying. E.g:
location / {
uwsgi_pass 127.0.0.1:4002;
include uwsgi_params;
# Uncomment this section to permit only allowing one user to access Galaxy during mainteance periods.
#if ($remote_addr ~* aaa.bbb.ccc.ddd) {
# uwsgi_pass 127.0.0.1:4002;
#}
}
Whenever we need to activate "maintenance mode", we swap the first uwsgi_pass to something unrelated like :9999 which isn't a proper uwsgi server. This causes the default response for people visiting our galaxy to be the 5xx error page (which we customize quite heavily).
Then the remote_addr is set to my IP address and only I can access galaxy while everyone else gets a nice maintenance page where I document what changes are being made, why, when the maintenance window is expected to end, etc.
Most helpful comment
We achieved the same effect with some fancy proxying. E.g:
Whenever we need to activate "maintenance mode", we swap the first
uwsgi_passto something unrelated like :9999 which isn't a proper uwsgi server. This causes the default response for people visiting our galaxy to be the5xxerror page (which we customize quite heavily).Then the remote_addr is set to my IP address and only I can access galaxy while everyone else gets a nice maintenance page where I document what changes are being made, why, when the maintenance window is expected to end, etc.