Galaxy Monitoring with Reports
Overview
QuestionsObjectives
How to monitor a Galaxy service with the Reports application?
Requirements
Setup and start the Galaxy reports app.
- Galaxy Server administration
- Ansible: slides slides - tutorial hands-on
- Galaxy Installation with Ansible: slides slides - tutorial hands-on
Time estimation: 30 minutesSupporting MaterialsLast modification: Jul 23, 2021License: Tutorial Content is licensed under Creative Commons Attribution 4.0 International License The GTN Framework is MIT
The reports application gives some pre-configured analytics screens. These are very easy to setup and can help with debugging issues in Galaxy.
Agenda
Setting up Reports
The reports application is included with the Galaxy codebase and this tutorial assumes you’ve already done all of the setup required for Galaxy, systemd, uWSGI, and NGINX.
hands_on Hands-on: Setup Reports
First we add a basic configuration of the Reports app to the playbook templates. Create
templates/galaxy/config/
folder, if it doesn’t exist, and createtemplates/galaxy/config/reports.yml
with the following contents:--- /dev/null +++ b/templates/galaxy/config/reports.yml @@ -0,0 +1,26 @@ +uwsgi: + socket: 127.0.0.1:9001 + buffer-size: 16384 + processes: 1 + threads: 4 + offload-threads: 2 + static-map: /static/style={{ galaxy_server_dir }}/static/style/blue + static-map: /static={{ galaxy_server_dir }}/static + static-map: /favicon.ico=static/favicon.ico + master: true + virtualenv: {{ galaxy_venv_dir }} + pythonpath: {{ galaxy_server_dir }}/lib + mount: /reports=galaxy.webapps.reports.buildapp:uwsgi_app() + manage-script-name: true + thunder-lock: false + die-on-term: true + hook-master-start: unix_signal:2 gracefully_kill_them_all + hook-master-start: unix_signal:15 gracefully_kill_them_all + py-call-osafterfork: true + enable-threads: true +reports: + cookie-path: /reports + database_connection: "{{ galaxy_config.galaxy.database_connection }}" + file_path: /data + filter-with: proxy-prefix + template_cache_path: "{{ galaxy_mutable_data_dir }}/compiled_templates"
In your
galaxyservers
group variables file, tell the playbook to deploy the reports configuration file:--- a/group_vars/galaxyservers.yml +++ b/group_vars/galaxyservers.yml @@ -51,6 +51,7 @@ galaxy_root: /srv/galaxy galaxy_user: {name: galaxy, shell: /bin/bash} galaxy_commit_id: release_20.09 galaxy_force_checkout: true +galaxy_reports_path: "{{ galaxy_config_dir }}/reports.yml" miniconda_prefix: "{{ galaxy_tool_dependency_dir }}/_conda" miniconda_version: 4.7.12 miniconda_manage_dependencies: false @@ -134,6 +135,8 @@ galaxy_config_templates: dest: "{{ galaxy_config.galaxy.dependency_resolvers_config_file }}" - src: templates/galaxy/config/tool_destinations.yml dest: "{{ galaxy_config.galaxy.tool_destinations_config_file }}" + - src: templates/galaxy/config/reports.yml + dest: "{{ galaxy_reports_path }}" galaxy_local_tools: - testing.xml
Similar to Galaxy we will again use systemd to manage the Reports process.
--- a/group_vars/galaxyservers.yml +++ b/group_vars/galaxyservers.yml @@ -147,6 +147,7 @@ galaxy_dynamic_job_rules: # systemd galaxy_manage_systemd: yes +galaxy_manage_systemd_reports: yes galaxy_systemd_env: [DRMAA_LIBRARY_PATH="/usr/lib/slurm-drmaa/lib/libdrmaa.so.1"] # Certbot
Then we need to tell NGINX it should serve our Reports app under
<server_url>/reports
url. Edit yourtemplates/nginx/galaxy.j2
file, and within the server block, add a block for proxying the reports application. It should look like:--- a/templates/nginx/galaxy.j2 +++ b/templates/nginx/galaxy.j2 @@ -76,4 +76,10 @@ server { uwsgi_param UWSGI_SCHEME $scheme; include uwsgi_params; } + + location /reports/ { + uwsgi_pass 127.0.0.1:9001; + uwsgi_param UWSGI_SCHEME $scheme; + include uwsgi_params; + } }
Run the playbook:
code-in Input: Bash
ansible-playbook galaxy.yml
The reports application should be available, under
<server_url>/reports/
.>
1.sh
comment Insecure!
But notice that your Reports server is not secured! Check out the External Authentication tutorial for information on securing Reports.
Key points
Galaxy supports pluggable monitoring extensions.
The Reports webapp is one option to monitor your system.
Frequently Asked Questions
Have questions about this tutorial? Check out the FAQ page for the Galaxy Server administration topic to see if your question is listed there. If not, please ask your question on the GTN Gitter Channel or the Galaxy Help ForumFeedback
Did you use this material as an instructor? Feel free to give us feedback on how it went.
Citing this Tutorial
- Nate Coraor, Björn Grüning, Simon Gladman, Helena Rasche, 2021 Galaxy Monitoring with Reports (Galaxy Training Materials). https://training.galaxyproject.org/archive/2021-09-01/topics/admin/tutorials/reports/tutorial.html Online; accessed TODAY
- Batut et al., 2018 Community-Driven Data Analysis Training for Biology Cell Systems 10.1016/j.cels.2018.05.012
details BibTeX
@misc{admin-reports, author = "Nate Coraor and Björn Grüning and Simon Gladman and Helena Rasche", title = "Galaxy Monitoring with Reports (Galaxy Training Materials)", year = "2021", month = "07", day = "23" url = "\url{https://training.galaxyproject.org/archive/2021-09-01/topics/admin/tutorials/reports/tutorial.html}", note = "[Online; accessed TODAY]" } @article{Batut_2018, doi = {10.1016/j.cels.2018.05.012}, url = {https://doi.org/10.1016%2Fj.cels.2018.05.012}, year = 2018, month = {jun}, publisher = {Elsevier {BV}}, volume = {6}, number = {6}, pages = {752--758.e1}, author = {B{\'{e}}r{\'{e}}nice Batut and Saskia Hiltemann and Andrea Bagnacani and Dannon Baker and Vivek Bhardwaj and Clemens Blank and Anthony Bretaudeau and Loraine Brillet-Gu{\'{e}}guen and Martin {\v{C}}ech and John Chilton and Dave Clements and Olivia Doppelt-Azeroual and Anika Erxleben and Mallory Ann Freeberg and Simon Gladman and Youri Hoogstrate and Hans-Rudolf Hotz and Torsten Houwaart and Pratik Jagtap and Delphine Larivi{\`{e}}re and Gildas Le Corguill{\'{e}} and Thomas Manke and Fabien Mareuil and Fidel Ram{\'{\i}}rez and Devon Ryan and Florian Christoph Sigloch and Nicola Soranzo and Joachim Wolff and Pavankumar Videm and Markus Wolfien and Aisanjiang Wubuli and Dilmurat Yusuf and James Taylor and Rolf Backofen and Anton Nekrutenko and Björn Grüning}, title = {Community-Driven Data Analysis Training for Biology}, journal = {Cell Systems} }