From bded87c613c6568ae4009a6461410ef1c7d70e67 Mon Sep 17 00:00:00 2001 From: Helena Rasche Date: Mon, 9 Dec 2024 09:53:15 +0100 Subject: [PATCH 1/3] Fix filename --- topics/admin/tutorials/beacon/tutorial.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/topics/admin/tutorials/beacon/tutorial.md b/topics/admin/tutorials/beacon/tutorial.md index dc50b5b85af9bb..7f5aea8b164200 100644 --- a/topics/admin/tutorials/beacon/tutorial.md +++ b/topics/admin/tutorials/beacon/tutorial.md @@ -304,7 +304,7 @@ Now that our beacon is running, we need to get data from Galaxy to the Beacon > > > Bash > > ```bash -> > ansible-playbook beacon-importer.yml +> > ansible-playbook beacon-import.yml > > ``` > > {: data-cmd="true"} > {: .code-in } From 739eb7c53661a0c9254bdbac3af063a02560d2c8 Mon Sep 17 00:00:00 2001 From: Helena Rasche Date: Mon, 9 Dec 2024 09:56:11 +0100 Subject: [PATCH 2/3] re-order for the server to have access --- topics/admin/tutorials/beacon/tutorial.md | 122 +++++++++++----------- 1 file changed, 62 insertions(+), 60 deletions(-) diff --git a/topics/admin/tutorials/beacon/tutorial.md b/topics/admin/tutorials/beacon/tutorial.md index 7f5aea8b164200..0ff06199e8d365 100644 --- a/topics/admin/tutorials/beacon/tutorial.md +++ b/topics/admin/tutorials/beacon/tutorial.md @@ -160,69 +160,11 @@ This tutorial will guide you through setting up a [GA4GH Beacon](https://beacon- > > Here we again use some advanced features of Ansible's inventory system. Ansible knows the name of every hostname in the inventory. Now that we want to point the beacon configuration, either at the database which should be on `beacon_server`, or at Galaxy in `galaxyservers`, we ask the `groups` variable for what the inventory looks like. We use `[0]` to pull out the first hostname we find for both of those groups. > {: .tip} > -> 3. Add the beacon-server playbook -> -> {% raw %} -> ```diff -> --- /dev/null -> +++ b/beacon-server.yml -> @@ -0,0 +1,9 @@ -> +--- -> +- name: Beacon Server -> + hosts: beacon_server -> + become: true -> + become_user: root -> + vars_files: -> + - group_vars/secret.yml -> + roles: -> + - paprikant.beacon -> {% endraw %} -> ``` -> {: data-commit="Add beacon server playbook"} -> -> 5. Run the playbook -> -> > Bash -> > ```bash -> > ansible-playbook beacon-server.yml -> > ``` -> > {: data-cmd="true"} -> {: .code-in } -> -> TODO: Check that it works -> -{: .hands_on} - -## Setting up the Importer - -Now that our beacon is running, we need to get data from Galaxy to the Beacon - -> Setting up the Beacon Importer -> -> 1. Add the beacon-import playbook -> -> {% raw %} -> ```diff -> --- /dev/null -> +++ b/beacon-import.yml -> @@ -0,0 +1,9 @@ -> +--- -> +- name: Beacon Importer -> + hosts: beacon_import -> + become: true -> + become_user: root -> + vars_files: -> + - group_vars/secret.yml -> + roles: -> + - paprikant.beacon-importer -> {% endraw %} -> ``` -> {: data-commit="Add beacon importer playbook"} -> > 1. Edit your `group_vars/secret.yml` and define some random passwords: > > - The API key for your account, which must be an admin -> +> - A password for the beacon database +> > {% snippet faqs/galaxy/preferences_admin_api_key.md admin=true %} > > > Bash @@ -300,6 +242,66 @@ Now that our beacon is running, we need to get data from Galaxy to the Beacon > > --> > +> +> 3. Add the beacon-server playbook +> +> {% raw %} +> ```diff +> --- /dev/null +> +++ b/beacon-server.yml +> @@ -0,0 +1,9 @@ +> +--- +> +- name: Beacon Server +> + hosts: beacon_server +> + become: true +> + become_user: root +> + vars_files: +> + - group_vars/secret.yml +> + roles: +> + - paprikant.beacon +> {% endraw %} +> ``` +> {: data-commit="Add beacon server playbook"} +> +> 5. Run the playbook +> +> > Bash +> > ```bash +> > ansible-playbook beacon-server.yml +> > ``` +> > {: data-cmd="true"} +> {: .code-in } +> +> TODO: Check that it works +> +{: .hands_on} + +## Setting up the Importer + +Now that our beacon is running, we need to get data from Galaxy to the Beacon + +> Setting up the Beacon Importer +> +> 1. Add the beacon-import playbook +> +> {% raw %} +> ```diff +> --- /dev/null +> +++ b/beacon-import.yml +> @@ -0,0 +1,9 @@ +> +--- +> +- name: Beacon Importer +> + hosts: beacon_import +> + become: true +> + become_user: root +> + vars_files: +> + - group_vars/secret.yml +> + roles: +> + - paprikant.beacon-importer +> {% endraw %} +> ``` +> {: data-commit="Add beacon importer playbook"} +> > 1. Run the playbook > > > Bash From 38fff7079c26974409852c740c9ba4b706b60061 Mon Sep 17 00:00:00 2001 From: Helena Rasche Date: Mon, 9 Dec 2024 10:00:11 +0100 Subject: [PATCH 3/3] Document installing missing collection Maybe someone will fix this someday. --- topics/admin/tutorials/beacon/tutorial.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/topics/admin/tutorials/beacon/tutorial.md b/topics/admin/tutorials/beacon/tutorial.md index 0ff06199e8d365..32819fb646d2c8 100644 --- a/topics/admin/tutorials/beacon/tutorial.md +++ b/topics/admin/tutorials/beacon/tutorial.md @@ -114,6 +114,19 @@ This tutorial will guide you through setting up a [GA4GH Beacon](https://beacon- > > {: data-cmd="true"} > {: .code-in} > +> 2. Install the docker role as well. +> +> > Bash +> > ```bash +> > ansible-galaxy collection install community.docker +> > ``` +> > {: data-cmd="true"} +> {: .code-in} +> +> > Why doesn't this use the requirements.yml? +> > Ansible over time added the feature of 'collections' in addition to roles. It's a nice and convenient method for grouping roles together. Unfortunately this means we need to update a significant portion of the GAT learning path to use this, which we have not done yet, as it will take a bit of time to do. Collections come with the unpleasant additional aspect that they will be installed into a different path than roles, so we'll need to add a `collections` folder as well, or maybe `deps/collections` and `deps/roles` folders. When this happens we'll have to additionally modify the ansible.cfg to look for collections in this additional path. +> {: .tip} +> > 3. Create the vars file > > {% raw %}