From d98cb760d3d25672cb36c773953b3bdb3728bf2f Mon Sep 17 00:00:00 2001 From: Helena Rasche Date: Tue, 12 Dec 2023 11:25:02 +0100 Subject: [PATCH] Improve my.galaxy.training --- _layouts/base.html | 2 +- assets/css/main.scss | 3 +- faqs/galaxy/workflows_run_ds.md | 31 ++++ faqs/galaxy/workflows_run_trs.md | 2 +- faqs/galaxy/workflows_run_wfh.md | 30 ++++ faqs/gtn/my-galaxy-training.md | 30 ++++ news/_posts/2023-12-12-tutorial-run-wfh-ds.md | 20 +++ short/galaxy.html | 158 ++++++++++++------ .../create-new-tutorial-content/tutorial.md | 36 ++++ 9 files changed, 262 insertions(+), 50 deletions(-) create mode 100644 faqs/galaxy/workflows_run_ds.md create mode 100644 faqs/galaxy/workflows_run_wfh.md create mode 100644 faqs/gtn/my-galaxy-training.md create mode 100644 news/_posts/2023-12-12-tutorial-run-wfh-ds.md diff --git a/_layouts/base.html b/_layouts/base.html index b7b1a3a3207d32..a22261b14d8a35 100644 --- a/_layouts/base.html +++ b/_layouts/base.html @@ -31,7 +31,7 @@ {% if page.title %} {% assign og_title = page.title %} {% endif %} - {% assign og_desc = page.description | default:topic.summary | default: "Collection of tutorials developed and maintained by the worldwide Galaxy community" %} + {% assign og_desc = page.description | default: page.excerpt | default:topic.summary | default: "Collection of tutorials developed and maintained by the worldwide Galaxy community" %} diff --git a/assets/css/main.scss b/assets/css/main.scss index 69d0c559fdfc91..c0588d0e8c9337 100644 --- a/assets/css/main.scss +++ b/assets/css/main.scss @@ -1249,7 +1249,8 @@ li { // The default presentation body { .show-when-galaxy-proxy-active { - cursor: not-allowed; + // cursor: not-allowed; + display: none; } span.tool, span.workflow { diff --git a/faqs/galaxy/workflows_run_ds.md b/faqs/galaxy/workflows_run_ds.md new file mode 100644 index 00000000000000..63afaeff7de234 --- /dev/null +++ b/faqs/galaxy/workflows_run_ds.md @@ -0,0 +1,31 @@ +--- +title: Importing and Launching a Dockstore workflow +area: workflows +box_type: hands_on +layout: faq +contributors: [hexylena] +--- + +{% if include.dockstore_id %} + +
+ +Click here to run {{ include.title }} + +
+ +
+ +Click here to run {{ include.title }} + + +
+ +{% else %} + +1. Go to [Workflow β†’ Import](https://my.galaxy.training/?path=/workflows/import) in your Galaxy +2. Switch tabs to TRS ID +3. Ensure the TRS server is set to "dockstore.org" +4. Provide your workflow hub ID + +{% endif %} diff --git a/faqs/galaxy/workflows_run_trs.md b/faqs/galaxy/workflows_run_trs.md index 465c6ad3f1b30f..d7dc7fc59e7e82 100644 --- a/faqs/galaxy/workflows_run_trs.md +++ b/faqs/galaxy/workflows_run_trs.md @@ -7,7 +7,7 @@ contributors: [hexylena] ---
-Click here to run the +Click here to run {{ include.title }} workflow.
diff --git a/faqs/galaxy/workflows_run_wfh.md b/faqs/galaxy/workflows_run_wfh.md new file mode 100644 index 00000000000000..ac4a4751c60fa4 --- /dev/null +++ b/faqs/galaxy/workflows_run_wfh.md @@ -0,0 +1,30 @@ +--- +title: Importing and Launching a WorkflowHub.eu Workflow +area: workflows +box_type: hands_on +layout: faq +contributors: [hexylena] +--- + +{% if include.wfhub_id %} + +
+ +Click here to run {{ include.title }} + +
+ +
+ +Click here to run {{ include.title }} + +
+ +{% else %} + +1. Go to [Workflow β†’ Import](https://my.galaxy.training/?path=/workflows/import) in your Galaxy +2. Switch tabs to TRS ID +3. Ensure the TRS server is set to "workflowhub.eu" +4. Provide your workflow hub ID + +{% endif %} diff --git a/faqs/gtn/my-galaxy-training.md b/faqs/gtn/my-galaxy-training.md new file mode 100644 index 00000000000000..9adfed07f85e77 --- /dev/null +++ b/faqs/gtn/my-galaxy-training.md @@ -0,0 +1,30 @@ +--- +title: What is my.galaxy.training +area: introduction +layout: faq +box_type: tip +contributors: [hexylena] +--- + +The [`my.galaxy.training`](https://my.galaxy.training) is part of the GTN. We found that often need to direct our learners to specific pages within Galaxy, but which Galaxy? Should we add three links, one for each of the current bigger UseGalaxy.* servers? That would be really annoying for users who aren't using one of those servers. + +E.g. how do we link to [/user](https://my.galaxy.training/?path=/user), the user preferences page which is available on every Galaxy Instance? This service handles that in a private and user-friendly manner. + +## (Learners) How to Use It + +When you access a my.galaxy.training page you'll be prompted to select a server, simply select one and you're good to go! + +If you want to enter a private Galaxy instance, perhaps, behind a firewall, that's also an option! Just select the 'other' option and provide your domain. Since the redirection happens in your browser with no servers involved, as long as *you* can access the server, you'll get redirected to the right location. + +## (Tutorial Authors) How to use it + +If you want to link to a specific page within Galaxy, simple construct the URL: `https://my.galaxy.training/?path=/user` where everything after `?path` is the location they should be redirected to on Galaxy. That example link will eventually redirect the learner to something like `https://usegalaxy.eu/user`. + +## Technical Background + +So we took inspiration from [Home Assistant](https://my.home-assistant.io/) which had the same problem, how to redirect users to pages on their own servers. The `my.galaxy.training` service is a very simple static page which looks in the user's [`localStorage`](https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage) for their preferred server. +If it's not set, the user can click one of the common domains, and be redirected. When they access another link, they'll be prompted to use a button that remembers which server they chose. + +## Data Privacy + +Any domain selected is not tracked nor communicated to any third party. Your preferred server is stored in your browser, and never transmitted to the GTN. That's why we use localStorage instead of cookies. diff --git a/news/_posts/2023-12-12-tutorial-run-wfh-ds.md b/news/_posts/2023-12-12-tutorial-run-wfh-ds.md new file mode 100644 index 00000000000000..1548a1fd97a963 --- /dev/null +++ b/news/_posts/2023-12-12-tutorial-run-wfh-ds.md @@ -0,0 +1,20 @@ +--- +title: "Tutorial Feature: Easier launching of WorkflowHub & Dockstore Workflows" +contributions: + authorship: [hexylena] + funding: [by-covid] +tags: [feature update, gtn, tutorials] +layout: news +--- + +While most GTN tutorials include their associated workflow directly in the GTN, some may wish to write a tutorial about running workflows from WorkflowHub, e.g. leveraging the [IWC workflow collection](https://workflowhub.eu/projects/33). + +We've added two snippets which make that easier than ever: + +{% snippet faqs/galaxy/workflows_run_wfh.md title="gromacs-mmgbsa/main" wfhub_id="248" %} + +And one for Dockstore: + +{% snippet faqs/galaxy/workflows_run_ds.md title="My Cool Workflow" dockstore_id="workflow/github.com/jmchilton/galaxy-workflow-dockstore-example-1/mycoolworkflow" %} + +You can read more about these snippets and how to use them yourself in your tutorials in the [GTN Contribution Guide section on Workflows]({% link topics/contributing/tutorials/create-new-tutorial-content/tutorial.md %}#workflows). diff --git a/short/galaxy.html b/short/galaxy.html index 4ba34bf0072675..0d15734635e857 100644 --- a/short/galaxy.html +++ b/short/galaxy.html @@ -1,60 +1,124 @@ --- layout: base +title: My Galaxy Training +description: This page will redirect you to a specific page in your preferred Galaxy instance. --- -

My Galaxy Instance

+
+
+
+

My Galaxy Training

-

-My Galaxy Instance allows the GTN to link you to specific pages in your preferred Galaxy -

+

+ This page lets us redirect you to specific pages in your preferred Galaxy. See the FAQ for more information. +

-Go to your server - - - +

+ You are being redirected to +

+ +

Go!

+

+ Go to https://usegalaxy.eu +

+ +
+ Select your Preferred Galaxy Server +

+ UseGalaxy.eu 🌍πŸ‡ͺπŸ‡Ί + UseGalaxy.org πŸŒŽπŸ‡ΊπŸ‡Έ + UseGalaxy.org.au 🌏 + +

+
+
+
+ +
+ + + + -

-Configure My Galaxy Instance by entering your preferred Galaxy Server (e.g. usegalaxy.eu or usegalaxy.org.au) and clicking Save. -

-

-Note: This URL is only stored in your browser. -

diff --git a/topics/contributing/tutorials/create-new-tutorial-content/tutorial.md b/topics/contributing/tutorials/create-new-tutorial-content/tutorial.md index dfeb80218e11b7..ca4ac310ec8cce 100644 --- a/topics/contributing/tutorials/create-new-tutorial-content/tutorial.md +++ b/topics/contributing/tutorials/create-new-tutorial-content/tutorial.md @@ -920,6 +920,42 @@ The alternative is to figure out the ID for the tool you want to use: ![Finding the tool ID](../../images/tool-id.png) +## Workflows + +In some tutorials you aren't as interested in teaching users the individual steps for analysing data, but rather want to focus on some downstream aspects of analysis, or to showcase the best practice workflows that are already available for a user to use! In those cases it can be useful to have a nicer way of inviting the user to execute those steps. + +### WorkflowHub + +You can use a dedicated snippet to invite users to run a WorkflowHub workflow: + +{% raw %} +```markdown +{% snippet faqs/galaxy/workflows_run_wfh.md title="mRNA-Seq BY-COVID Pipeline" wfhub_id="685" %} +``` +{% endraw %} + +Rendered: + +{% snippet faqs/galaxy/workflows_run_wfh.md title="mRNA-Seq BY-COVID Pipeline" wfhub_id="685" %} + +Note that it links to a specific workflow, on any Galaxy server. When this tutorial is opened from within the Tutorial Mode, that link will change to one on the current server, removing the intermediate step. + +### Dockstore + +Please note that the dockstore ID should be provided without the `#` character. + +{% raw %} +```markdown +{% snippet faqs/galaxy/workflows_run_ds.md title="My Cool Workflow" dockstore_id="workflow/github.com/jmchilton/galaxy-workflow-dockstore-example-1/mycoolworkflow" %} +``` +{% endraw %} + +Rendered: + +{% snippet faqs/galaxy/workflows_run_ds.md title="My Cool Workflow" dockstore_id="workflow/github.com/jmchilton/galaxy-workflow-dockstore-example-1/mycoolworkflow" %} + +This snippet has the same behaviour, it will use my.galaxy.training links to make them server independent, but in Tutorial Mode it will open on the current server. + ## FAQs (snippets)