Skip to content

Commit 9129ef4

Browse files
committed
✨ feat(hello_nextflow/seqera): add run with launchpad section
⚰️ dead(hello_seqera): remove unused portions of basic training
1 parent 89f4c7a commit 9129ef4

8 files changed

+85
-194
lines changed

.devcontainer/devcontainer.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@
1818
"extensions": [
1919
"ms-python.python",
2020
"ms-python.vscode-pylance",
21-
"nf-core.nf-core-extensionpack"
21+
"nf-core.nf-core-extensionpack",
22+
"nextflow.nextflow",
23+
"codezombiech.gitignore"
2224
]
2325
}
2426
},

docs/hello_nextflow/10_hello_seqera.md

Lines changed: 0 additions & 154 deletions
Original file line numberDiff line numberDiff line change
@@ -19,157 +19,3 @@ You can use Seqera Platform via either the **CLI**, through the **online GUI** o
1919
--8<-- "docs/hello_nextflow/seqera/01_run_with_cli.md"
2020

2121
--8<-- "docs/hello_nextflow/seqera/02_run_with_launchpad.md"
22-
23-
--8<-- "docs/hello_nextflow/seqera/03_add_compute_environment.md"
24-
25-
--8<-- "docs/hello_nextflow/seqera/04_setup_launchpad.md"
26-
27-
!!! Warning WORK-IN-PROGRESS
28-
29-
Everything below this note is content that was copied from the original guide and needs to be moved or rewritten into the above subpages.
30-
31-
## Online GUI
32-
33-
To run using the GUI, there are three main steps:
34-
35-
1. Create an account and login into Seqera Platform, available free of charge, at [cloud.seqera.io](https://cloud.seqera.io).
36-
2. Create and configure a new [compute environment](https://docs.seqera.io/platform/24.1/compute-envs/overview).
37-
3. Start [launching pipelines](https://docs.seqera.io/platform/24.1/launch/launchpad#launchpad).
38-
39-
### Selecting a default compute environment
40-
41-
If you have more than one **Compute Environment**, you can select which one will be used by default when launching a pipeline.
42-
43-
1. Navigate to your [compute environments](https://docs.seqera.io/platform/24.1/compute-envs/overview).
44-
2. Choose your default environment by selecting the **Make primary** button.
45-
46-
**Congratulations!**
47-
48-
You are now ready to launch workflows with your primary compute environment.
49-
50-
### Launchpad
51-
52-
Launchpad makes it easy for any workspace user to launch a pre-configured pipeline.
53-
54-
![Launchpad](img/overview_launch.png)
55-
56-
A pipeline is a repository containing a Nextflow workflow, a compute environment and workflow parameters.
57-
58-
### Pipeline Parameters Form
59-
60-
Launchpad automatically detects the presence of a `nextflow_schema.json` in the root of the repository and dynamically creates a form where users can easily update the parameters.
61-
62-
!!! info
63-
64-
The parameter forms view will appear if the pipeline has a Nextflow schema file for the parameters. Please refer to the [Nextflow Schema guide](https://docs.seqera.io/platform/24.1/pipeline-schema/overview) to learn more about the schema file use-cases and how to create them.
65-
66-
This makes it trivial for users without any expertise in Nextflow to enter their workflow parameters and launch.
67-
68-
![Pipeline parameters](img/launch_rnaseq_nextflow_schema.png)
69-
70-
### Adding a new pipeline
71-
72-
Adding a pipeline to the pre-saved workspace launchpad is detailed in full on the [Seqera webpage docs](https://docs.seqera.io/platform/24.1/launch/launchpad#add-new-pipeline).
73-
74-
In brief, these are the steps you need to follow to set up a pipeline.
75-
76-
1. Select the Launchpad button in the navigation bar. This will open the **Launch Form**.
77-
2. Select a [compute environment](https://docs.seqera.io/platform/24.1/compute-envs/overview).
78-
3. Enter the repository of the workflow you want to launch. e.g. <https://github.com/nf-core/rnaseq.git>
79-
4. Select a workflow **Revision number**. The Git default branch (main/master) or `manifest.defaultBranch` in the Nextflow configuration will be used by default.
80-
5. Set the **Work directory** location of the Nextflow work directory. The location associated with the compute environment will be selected by default.
81-
6. Enter the name(s) of each of the Nextflow **Config profiles** followed by the `Enter` key. See the Nextflow [Config profiles](https://www.nextflow.io/docs/latest/config.html#config-profiles) documentation for more details.
82-
7. Enter any workflow parameters in YAML or JSON format. YAML example:
83-
84-
```yaml
85-
reads: "s3://nf-bucket/exome-data/ERR013140_{1,2}.fastq.bz2"
86-
paired_end: true
87-
```
88-
89-
8. Select Launch to begin the pipeline execution.
90-
91-
!!! info
92-
93-
Nextflow workflows are simply Git repositories and can be changed to any public or private Git-hosting platform. See [Git Integration](https://docs.seqera.io/platform/24.1/git/overview) in the Seqera Platform docs and [Pipeline Sharing](https://www.nextflow.io/docs/latest/sharing.html) in the Nextflow docs for more details.
94-
95-
!!! note
96-
97-
The credentials associated with the compute environment must be able to access the work directory.
98-
99-
!!! info
100-
101-
In the configuration, the full path to a bucket must be specified with single quotes around strings and no quotes around booleans or numbers.
102-
103-
!!! tip
104-
105-
To create your own customized Nextflow Schema for your workflow, see the examples from the `nf-core` workflows that have adopted this approach. For example, [eager](https://github.com/nf-core/eager/blob/2.3.3/nextflow_schema.json) and [rnaseq](https://github.com/nf-core/rnaseq/blob/3.0/nextflow_schema.json).
106-
107-
For advanced settings options check out this [page](https://docs.seqera.io/platform/24.1/launch/launchpad#advanced-settings).
108-
109-
There is also community support available if you get into trouble, join the Nextflow Slack by following this [link](https://www.nextflow.io/slack-invite.html).
110-
111-
!!! cboard-list-2 "Summary"
112-
113-
In this step you have learned:
114-
115-
1. How to create an account and login into Seqera Platform
116-
2. How to configure your compute environment.
117-
3. How to add, customize, and launch a pipeline with Seqera Platform.
118-
119-
## API
120-
121-
To learn more about using the Seqera Platform API, visit the [API section](https://docs.seqera.io/platform/24.1/api/overview) in the documentation.
122-
123-
## Workspaces and Organizations
124-
125-
Seqera Platform simplifies the development and execution of pipeline by providing a centralized interface for users and organizations.
126-
127-
Each user has a unique **workspace** where they can interact and manage all resources such as workflows, compute environments and credentials. Details of this can be found [here](https://docs.seqera.io/platform/24.1/getting-started/workspace-setup).
128-
129-
Organisations can have multiple workspaces with customized access for specific organisation **members** and **collaborators**.
130-
131-
### Organization resources
132-
133-
You can create your own organization and participant workspace by following the docs at [Seqera](https://docs.seqera.io/platform/24.1/orgs-and-teams/workspace-management).
134-
135-
Seqera Platform allows the creation of multiple organizations, each of which can contain multiple workspaces with shared users and resources. This allows any organization to customize and organize the usage of resources while maintaining an access control layer for users associated with a workspace.
136-
137-
### Organization users
138-
139-
Any user can be added or removed from a particular organization or a workspace and can be allocated a specific access role within that workspace.
140-
141-
The Teams feature provides a way for organizations to group various users and participants together into teams. For example, `workflow-developers` or `analysts`, and apply access control to all the users within this team collectively.
142-
143-
For further information, please refer to the [User Management](https://docs.seqera.io/platform/24.1/orgs-and-teams/organizations) section.
144-
145-
### Setting up a new organization
146-
147-
Organizations are the top-level structure and contain Workspaces, Members, Teams and Collaborators.
148-
149-
To create a new Organization:
150-
151-
1. Click on the dropdown next to your name and select New organization to open the creation dialog.
152-
2. On the dialog, fill in the fields as per your organization. The Name and Full name fields are compulsory.
153-
154-
!!! note
155-
156-
A valid name for the organization must follow a specific pattern. Please refer to the UI for further instructions.
157-
158-
3. The rest of the fields such as Description, Location, Website URL and Logo Url are optional.
159-
4. Once the details are filled in, you can access the newly created organization using the organization’s page, which lists all of your organizations.
160-
161-
!!! note
162-
163-
It is possible to change the values of the optional fields either using the Edit option on the organization’s page or by using the Settings tab within the organization page, provided that you are the Owner of the organization.
164-
165-
!!! tip
166-
167-
A list of all the included Members, Teams and Collaborators can be found on the organization page.
168-
169-
!!! cboard-list-2 "Summary"
170-
171-
In this step you have learned:
172-
173-
1. How to create a new organization
174-
2. How to access the newly created organization
175-
3. How to change organization settings
Lines changed: 82 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,85 @@
11
## 2 Using Seqera Platform Launchpad to run Nextflow workflows
22

3-
### 2.1. Navigate to the community/showcase workspace and launch a pipeline
3+
So far we've been running Nextflow workflows on our local machine using the command line interface but sending the logs to Seqera Platform for monitoring and visualization.
4+
Next we want to start using Seqera Platform to launch Nextflow workflows on our behalf.
45

5-
### 2.2. Monitor the execution of a test rna-seq pipeline
6+
!!! Note "Community Showcase"
7+
8+
Having a compute environment capable of running Nextflow workflows configured in Seqera Platform is normally a prerequisite for this task.
9+
But we want to see how it works before we put in that effort, so we'll start by launching a job in community/showcase workspace which has a compute environment already set up.
10+
11+
!!! tip "Trainer Tip"
12+
13+
Launch a test run of the nf-core/rnaseq pipeline in the community/showcase workspace prior to starting this session, so you'll have a recent run for participants to inspect.
14+
15+
### 2.1. Navigate to the community/showcase workspace
16+
17+
Seqera Platform has a concept of [**organizations**](https://docs.seqera.io/platform/latest/orgs-and-teams/organizations) and [**workspaces**](https://docs.seqera.io/platform/latest/orgs-and-teams/workspace-management) which are used to organize and share [pipelines](https://docs.seqera.io/platform/latest/launch/launchpad), [compute environments](https://docs.seqera.io/platform/latest/compute-envs/overview), [data](https://docs.seqera.io/platform/latest/data/data-explorer), [credentials](https://docs.seqera.io/platform/latest/credentials/overview), and more.
18+
The `community/showcase` workspace is a public workspace where you can see some example pipelines and compute environments.
19+
Each user has an alloted amount of free compute to use in this workspace.
20+
21+
Click on your username in the top left corner of the screen to bring up the list of organizations and workspaces you have access to.
22+
Select the `community/showcase` workspace.
23+
24+
### 2.2. Launch a test run of nf-core/rnaseq pipeline
25+
26+
In the `community/showcase` workspace, you will see a list of pipelines that have been set up by the workspace owner for you to run.
27+
Follow these steps to launch a test run of a pipeline:
28+
29+
![Launchpad](seqera/img/launchpad.gif)
30+
31+
1. Find the `nf-core-rnaseq` pipeline in the list of pipelines.
32+
2. Click on the `Launch` button to bring up the launch form.
33+
3. Change the "Workflow run name" to "<username>-rnaseq-test".
34+
4. Click "Next" to bring up the parameters form.
35+
5. Find the `trimmer` parameter and change it to `fastp`.
36+
6. Click to "Next" to inspect the advanced configuration.
37+
7. Click "Launch" to start the pipeline!
38+
39+
!!! Tip
40+
41+
In the advanced configuration, you'll see a section named "Pre-run script" with a script similar to the following:
42+
43+
```bash
44+
export NXF_FILE_ROOT=s3://nf-tower-bucket/scratch/$TOWER_WORKFLOW_ID
45+
```
46+
47+
This is what ensures that everyone's pipeline will write to a unique location in cloud storage despite all having the `outdir` parameter set to `./results`.
48+
49+
### 2.3. Monitor the pipeline run
50+
51+
After launching the pipeline, you will be taken to the pipeline run page where you can monitor the progress of the pipeline.
52+
It may take some time for the pipeline to start running while AWS Batch spins up the needed resources, so go to the "Runs" tab above the pipeline and open a recent completed (or failed) run by one of your "teammates" in the community.
53+
54+
### 2.4. Inspect a pipeline run
55+
56+
Scroll down to find the list of tasks that were executed in the pipeline run.
57+
For example, by searching for `fastq` we can find the task `NFCORE_RNASEQ:RNASEQ:FASTQ_FASTQC_UMITOOLS_FASTP:FASTP (WT_REP2)` that was executed as part of the pipeline.
58+
59+
Click on the task to see the task details:
60+
61+
![Task details](seqera/img/task_details.png)
62+
63+
1. Find the following details on the "About" page for the the task you're inspecting:
64+
65+
- [ ] How long did the task script run (not including scheduling time)?
66+
- [ ] How many CPUs were allocated to the task?
67+
- [ ] What was the virtual machine type that the task ran on?
68+
- [ ] What was the estimated cost of the task?
69+
70+
2. Explore the Execution Log tab. What information is available here?
71+
72+
3. Explore the Data Explorer tab. Note that the work directory structure we've seen during local runs is replicated here in cloud storage!
73+
74+
### Takeaway
75+
76+
You have learned how to:
77+
78+
- Switch between organizations and workspaces in Seqera Platform.
79+
- Launch a Nextflow pipeline that ran in the cloud using Seqera Platform.
80+
- Monitor the progress of the pipeline run.
81+
- Inspect the details of a task that was executed as part of the pipeline.
82+
83+
### Next steps
84+
85+
In the next section, we will learn how to set up a compute environment in Seqera Platform to run our own Nextflow workflows.

docs/hello_nextflow/seqera/03_add_compute_environment.md

Lines changed: 0 additions & 26 deletions
This file was deleted.

docs/hello_nextflow/seqera/04_setup_launchpad.md

Lines changed: 0 additions & 11 deletions
This file was deleted.
12.4 MB
Loading
Loading
Loading

0 commit comments

Comments
 (0)