Skip to content

Commit e0b1161

Browse files
authored
Merge pull request #6385 from scorreard/codex_LP
Addition of the last section (lab creation) of the codex learning pathway
2 parents aaea1a6 + 5d7a132 commit e0b1161

File tree

3 files changed

+175
-5
lines changed

3 files changed

+175
-5
lines changed

learning-pathways/sig-and-codex-creation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ pathway:
4848
topic: community
4949
- name: community-workflow-table
5050
topic: community
51-
#- name: community-lab
52-
# topic: community
51+
- name: community-lab
52+
topic: community
5353

5454

5555
- section: "Module 2: Create a Special Interest Group (SIG)"
Lines changed: 170 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,170 @@
1+
---
2+
layout: tutorial_hands_on
3+
title: Creation of the labs in the different Galaxy instances for your community
4+
level: Introductory
5+
redirect_from:
6+
- /topics/dev/tutorials/community-lab/tutorial
7+
subtopic: sig
8+
9+
questions:
10+
- How can I create a lab for a Galaxy community?
11+
objectives:
12+
- Create labs for Galaxy communities
13+
time_estimation: 1H
14+
key_points:
15+
- The Community lab is a centralised webpage built on the Galaxy framework that enables communities to use specific tools, workflows and tutorials on different Galaxy servers.
16+
tags:
17+
- Community
18+
- SIG
19+
- CoDex
20+
contributions:
21+
authorship:
22+
- bebatut
23+
- paulzierep
24+
- scorreard
25+
- BirdmanRidesAgain
26+
27+
---
28+
29+
The **Community lab**, a centralised webpage that enables communities to rapidly aggregate, curate, integrate, display, and launch relevant tools, workflows, and training on different Galaxy servers. This user-friendly interface, built on the Galaxy framework, provides community members with data analysis capacity without requiring programming expertise. Users can run individual tools or create complex workflows, with full provenance tracking to ensure reproducibility, designed specifically for the community research (Nasr et al., 2024).
30+
*For example, [the microgalaxy lab (Europe)](https://microbiology.usegalaxy.eu).*
31+
32+
33+
The aim is this tutorial is to create the files necessary to display the labs in each Galaxy instance.
34+
35+
You can also use the [Galaxy Labs engine](https://labs.usegalaxy.org.au).
36+
37+
> <agenda-title></agenda-title>
38+
>
39+
> In this tutorial, we will cover:
40+
>
41+
> 1. TOC
42+
> {:toc}
43+
>
44+
{: .agenda}
45+
46+
# Create the lab specific files (automatic)
47+
48+
The labs are composed of various files, some that are specific to your community and some that are common between all the labs.
49+
To automatically create the necessary files from a set of templates, a script was generated ("`sources/bin/populate_labs.sh`)
50+
51+
This script will create the following structure and files:
52+
communities/<your community>/lab/
53+
CONTRIBUTORS
54+
README.md
55+
base.yml
56+
conclusion.html
57+
intro.html
58+
usegalaxy.eu.yml
59+
usegalaxy.fr.yml
60+
usegalaxy.org.yml
61+
62+
communities/<your community>/lab/sections_templates/
63+
1_data_import_and_preparation.yml
64+
2_tools.yml
65+
3_workflows.yml
66+
4_tutorials.yml
67+
5_support_and_help.yml
68+
6_community.yml
69+
70+
{% include _includes/cyoa-choices.html option1="GitHub_Actions" option2="Command-line" default="GitHub_Actions"
71+
text="The files can be created in two wyas, using GitHub actions (on the GitHub interface) or using the command line to launch a script." %}
72+
73+
<div class="GitHub_Actions" markdown="1">
74+
75+
> <hands-on-title>Generate the files using Github Actions</hands-on-title>
76+
>
77+
> 1. Go to the [Galaxy Codex repo](https://github.com/galaxyproject/galaxy_codex)
78+
> 2. Go to the file `.github/workflows/populate_labs.yaml`
79+
> 3. On the right, click on the pen to "dit this file"
80+
> 4. Duplicate section called "Populate biodiversity Lab"
81+
>
82+
> For example:
83+
> ```
84+
> - name: Populate biodiversity Lab
85+
> run: |
86+
> bash sources/bin/populate_labs.sh
87+
> env:
88+
> COMMUNITY: biodiversity
89+
> ```
90+
> 5. Change the name and community name for your community
91+
> 6. Commit changes the changes to a new branch that you name "new lab for <Community-name>"
92+
> 7. On the top panel of the Galaxy codex repository, click on "Actions"
93+
> 8. On the left panel, click on "Populate labs"
94+
> 9. In the table, click on "Run workflow" and select the branch you just created "new lab for <Community-name>"
95+
> 10. Click on "Run workflow"
96+
>
97+
> This will create a Pull Request with the new files in the appropriate community folder. To find the Pull Request, on the top panel of the Galaxy codex repository, click on "Pull requests".
98+
{: .hands_on}
99+
100+
</div>
101+
102+
<div class="Command-line" markdown="1">
103+
104+
> <hands-on-title>Generate the files using the command line</hands-on-title>
105+
>
106+
> 1. Fork and clone the [Galaxy Codex repo](https://github.com/galaxyproject/galaxy_codex)
107+
> 2. Set the `COMMUNITY` variable : `export $COMMUNITY=<your community>`
108+
> 3. Lauch `sources/bin/populate_labs.sh`
109+
>
110+
> This will create a bunch of the new files in the appropriate community folder (communities/<your community>/lab/).
111+
{: .hands_on}
112+
113+
</div>
114+
115+
# Modify the generated files to personalize your community lab
116+
117+
Depending on how you generated the files (GitHub actions or command-line), you should be able to find your community specific lab files.
118+
If you generated the files using the GitHub Actions, this will be in the automatically generated pull request.
119+
If you generated the files using the command line, this will be in the local folder that were generated.
120+
121+
Files to update :
122+
- "communities/<your community>/lab/CONTRIBUTORS" --> Add the handles of everyone who contributed in the lab
123+
- "communities/<your community>/lab/README.md" --> Change all >your-community> by your community name
124+
- "communities/<your community>/lab/base.yml" --> Change all >your-community> by your community name
125+
- "communities/<your community>/lab/intro.html" --> Include a description of your community.
126+
127+
Files that do not require a manual update :
128+
- "communities/<your community>/lab/conclusion.html" --> No change required.
129+
- "communities/<your community>/lab/sections/*" --> No change required.
130+
131+
The files in the section folders contain the code for each table visible in the lab.
132+
You can check different labs for inspiration, such as the [microgalaxy lab](https://microbiology.usegalaxy.eu).
133+
134+
# Create community specific sections to personalize your community lab
135+
136+
If you want additional sections, for example, the "Microbial isolates" and "Microbiome" sections in the [microgalaxy lab](https://microbiology.usegalaxy.eu/).
137+
138+
> <hands-on-title>Add community specific sections</hands-on-title>
139+
> 1. Find an appropriate template. You can use other files in your section folder, or browse other labs, such as [microgalaxy lab code](https://github.com/galaxyproject/galaxy_codex/tree/main/communities/microgalaxy/lab), and copy the raw code as a template.
140+
> 2. Create the file in your section folder. Name it with a digit (numerical order) and a descriptive name (i.e. "7_microbial_isolate").
141+
> 3. Copy the raw code in this newly created file.
142+
> 4. Update the code to display what you want.
143+
> 5. Save the file.
144+
> 6. Open `communities/<your community>/lab/base.yml`
145+
> 7. Add the previously created file in the sections (see [microgalaxy base file](https://github.com/galaxyproject/galaxy_codex/blob/main/communities/biodiversity/lab/base.yml) for example)
146+
> 8. Save `communities/<your community>/lab/base.yml`
147+
> 9. Commit the changes, create the pull request (if not done previously)
148+
{: .hands_on}
149+
150+
The Pull Request will be reviewed. Make sure to respond to any feedback.
151+
152+
# Include the labs in the different instances
153+
154+
For the lab to be accessible from the different instances, you need to add files in each instance independently.
155+
156+
For the French instance (https://usegalaxy.fr), all the steps are described in [Issue 297](https://gitlab.com/ifb-elixirfr/usegalaxy-fr/infrastructure/-/issues/297).
157+
You can use the [merge request done for the biodiversity lab](https://gitlab.com/ifb-elixirfr/usegalaxy-fr/infrastructure/-/merge_requests/1302) as a reference.
158+
159+
For the European instance (https://usegalaxy.eu), this tutorial will be updated later.
160+
You can use the [pull request done for the biodiversity lab](https://github.com/usegalaxy-eu/infrastructure-playbook/pull/1629) as a reference.
161+
162+
For the American instance (https://usegalaxy.org), this tutorial will be updated later.
163+
You can use the [pull request done for the biodiversity lab](https://github.com/galaxyproject/usegalaxy-playbook/pull/427) as a reference.
164+
165+
For the Australian instance (https://usegalaxy.org.au), this tutorial will be updated later.
166+
You can use the [pull request done for the biodiversity lab](https://github.com/usegalaxy-au/infrastructure/issues/2786#issuecomment-3330995427) as a reference.
167+
168+
# Conclusion
169+
170+
You now have all the files necessary to display your lab in several instances and they should soon be available to your users.

topics/community/tutorials/community-tool-table/tutorial.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,9 @@ To provide the research community with a comprehensive list of available Galaxy
3939

4040
![A diagram illustrating the Galaxy Codex pipeline, showcasing the various steps involved in creating a community Galaxy tool table.](./images/galaxy_tool_metadata_extractor_pipeline.png "Workflow of the Galaxy Codex pipeline. Tool wrappers are parsed from different repositories and additional metadata is retrieved from bio.tools, BioConda, and the main public Galaxy servers. Upon filtering and manual curation of the data for specific scientific communities, the data is transformed into interactive web tables and a tool usage statistic-base word cloud, that can be integrated into any website.")
4141

42-
The pipeline creates a [table with all tools and their metadata](https://galaxyproject.github.io/galaxy_codex/). This table can be **filtered to only include tools that are relevant to a specific research community**. Here is an example for the microbial related tools:
42+
The pipeline creates a [table with all tools and their metadata](https://galaxyproject.github.io/galaxy_codex/communities/). This table can be **filtered to only include tools that are relevant to a specific research community**. Here is an example for the microbial related tools:
4343

44-
<iframe id="edam" src="https://galaxyproject.github.io/galaxy_codex/microgalaxy/" frameBorder="0" width="100%" height="600px"> ![Interactive table for microgalaxy tools](./images/microgalaxy_tools.png) </iframe>
44+
<iframe id="edam" src="https://galaxyproject.github.io/galaxy_codex/communities/microgalaxy/resources/" frameBorder="0" width="100%" height="600px"> ![Interactive table for microgalaxy tools](./images/microgalaxy_tools.png) </iframe>
4545

4646
The generated community-specific table can be used as is (e.g. downloadable tsv file) and/or embedded (e.g. into a Galaxy Hub page or Galaxy subdomain). This table allows further filtering and searching for fine-grained tool selection.
4747

@@ -194,7 +194,7 @@ The interactive table you have created can be embedded in your community page on
194194
> width="100%"
195195
> height="600"
196196
> frameBorder="0"
197-
> src="https://galaxyproject.github.io/galaxy_codex/<your_community>/">
197+
> src="https://galaxyproject.github.io/galaxy_codex/communities/<your_community>/resources/">
198198
> </iframe>
199199
> ```
200200
>

0 commit comments

Comments
 (0)