Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ansible role/playbook for installation of compatibility layer #12

Merged
merged 21 commits into from
Sep 1, 2020

Conversation

bedroge
Copy link
Collaborator

@bedroge bedroge commented Jul 10, 2020

No description provided.

@bedroge bedroge linked an issue Jul 13, 2020 that may be closed by this pull request
@bedroge bedroge changed the title WIP: Ansible playbook for installation of compatibility layer Ansible role/playbook for installation of compatibility layer Aug 21, 2020
@bedroge
Copy link
Collaborator Author

bedroge commented Aug 21, 2020

I think this is ready to be reviewed now: I've added documentation and CI (Ansible Lint), and improved the playbook/role. One thing it doesn't do (yet?), is installing the Prefix itself. I'm not sure if the playbook should do this, but we can always add it later.

@peterstol / @boegel: could you do a review?

@bedroge
Copy link
Collaborator Author

bedroge commented Aug 21, 2020

I tested the playbook inside a VM with a clean Prefix installation (done with the Singularity container), by the way.

playbooks/install.yml Outdated Show resolved Hide resolved
playbooks/roles/compatibility-layer/defaults/main.yml Outdated Show resolved Hide resolved
playbooks/roles/compatibility-layer/tasks/add_overlay.yml Outdated Show resolved Hide resolved
playbooks/roles/compatibility-layer/tasks/main.yml Outdated Show resolved Hide resolved
@bedroge
Copy link
Collaborator Author

bedroge commented Aug 26, 2020

Thanks for the review @victorusu. Just made some changes based on your feedback.

victorusu
victorusu previously approved these changes Aug 26, 2020
Copy link
Contributor

@victorusu victorusu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link
Contributor

@cfenoy cfenoy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just for completion the publish transaction and abort transaction tasks should check that a transaction has been started.

playbooks/roles/compatibility-layer/tasks/main.yml Outdated Show resolved Hide resolved
playbooks/roles/compatibility-layer/tasks/main.yml Outdated Show resolved Hide resolved
peterstol and others added 2 commits September 1, 2020 11:04
Co-authored-by: Carles Fenoy <cfenoy@users.noreply.github.com>
Co-authored-by: Carles Fenoy <cfenoy@users.noreply.github.com>
Copy link
Contributor

@peterstol peterstol left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ansible scripts look good!

Tested on a local prefix with ansible-playbook -c local -i localhost, install.yml after setting cvmfs stuff to false and disabling Become =Yes, which is not required if you run as the same user as the prefix installation.

All TASKS Passed. A minor warning on gathering facts may need fixing later.

The result was a gentoo prefix installation with the EESSI overlay and lmod and archspec packages installed with the 2020.08 set.

PLAY [Install compatibility layer] **************************************************************************************************************

TASK [Gathering Facts] **************************************************************************************************************************
[WARNING]: error loading fact - please check content
ok: [localhost]

TASK [compatibility-layer : Check if a Prefix installation is found at the specified location] **************************************************
ok: [localhost]

TASK [compatibility-layer : Fail if the given Prefix path does not have emerge] *****************************************************************
skipping: [localhost]

TASK [compatibility-layer : Start transaction] **************************************************************************************************
skipping: [localhost]

TASK [compatibility-layer : include_tasks] ******************************************************************************************************
included: /scistor/gt/psl500/EESSI/compatibility-layer/playbooks/roles/compatibility-layer/tasks/add_overlay.yml for localhost

TASK [compatibility-layer : Install equery command (dependency for the portage module)] *********************************************************
changed: [localhost]

TASK [compatibility-layer : Create repos directory] *********************************************************************************************
changed: [localhost]

TASK [compatibility-layer : Install eselect-repository] *****************************************************************************************
changed: [localhost]

TASK [compatibility-layer : Install git] ********************************************************************************************************
changed: [localhost]

TASK [compatibility-layer : Check which repositories have been installed] ***********************************************************************
ok: [localhost]

TASK [compatibility-layer : Add custom overlay configuration] ***********************************************************************************
changed: [localhost]

TASK [compatibility-layer : Sync the repositories] **********************************************************************************************
ok: [localhost]

TASK [compatibility-layer : Make sets directory] ************************************************************************************************
changed: [localhost]

TASK [compatibility-layer : Make symlink to all package set files in the custom overlay] ********************************************************
changed: [localhost] => (item=2020.08)

TASK [compatibility-layer : include_tasks] ******************************************************************************************************
included: /scistor/gt/psl500/EESSI/compatibility-layer/playbooks/roles/compatibility-layer/tasks/install_packages.yml for localhost

TASK [compatibility-layer : Install package set] ************************************************************************************************
changed: [localhost] => (item=2020.08)

TASK [compatibility-layer : Install additional packages] ****************************************************************************************
ok: [localhost] => (item=None)

TASK [compatibility-layer : Publish transaction] ************************************************************************************************
skipping: [localhost]

PLAY RECAP **************************************************************************************************************************************
localhost                  : ok=15   changed=8    unreachable=0    failed=0    skipped=3    rescued=0    ignored=0

@peterstol peterstol merged commit 663f430 into master Sep 1, 2020
@bedroge bedroge deleted the ansible branch September 1, 2020 10:57
poksumdo pushed a commit to poksumdo/compatibility-layer that referenced this pull request Jun 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Ansible script to install packages
4 participants