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

Add GitLab based Kayobe-Automation #1471

Open
wants to merge 10 commits into
base: stackhpc/2024.1
Choose a base branch
from

Conversation

jackhodgkiss
Copy link
Contributor

Add support for GitLab based kayobe-automation complete with OpenBao for secret managment.

This commit adds the required collections and roles for GitLab CI to the
`etc/kayobe/ansible/requirements.yml` file.

Note: this will need changing before merging but is required until the
roles and collections been merged and released.
Includes steps for deploying GitLab runners, generating pipelines and
deploying OpenBao for secret management.
@jackhodgkiss jackhodgkiss self-assigned this Jan 21, 2025
@jackhodgkiss jackhodgkiss requested a review from a team as a code owner January 21, 2025 15:57
@product-auto-label product-auto-label bot added size: l ansible Ansible playbooks documentation Improvements or additions to documentation labels Jan 21, 2025
@jackhodgkiss jackhodgkiss force-pushed the add-gitlab-kayobe-automation branch from e1e5994 to 9a301fb Compare January 22, 2025 12:10
@jackhodgkiss jackhodgkiss force-pushed the add-gitlab-kayobe-automation branch 2 times, most recently from 8e675b7 to ff8d471 Compare January 22, 2025 13:23
Improve the docs based on feedback provided.

[skip ci]
@jackhodgkiss jackhodgkiss force-pushed the add-gitlab-kayobe-automation branch from ff8d471 to beaedd3 Compare January 27, 2025 11:41
Copy link
Member

@Alex-Welsh Alex-Welsh left a comment

Choose a reason for hiding this comment

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

I'm going through this deployment for a client at the moment and will add more comments as I go

Comment on lines +206 to +210
1. Identify a suitable host for hosting the runners.
Ideally an infra-vm would be deployed to allow for easily compartmentalising the runners from the rest of the environment.
8 VCPUs and 16GB of RAM is recommended for the guest machine however this may need to be adjusted for larger deployments.
Whether the host is in an infra-vm or not it will need access to the :code:`admin_network` or :code:`provision_oc_network`, :code:`public_network` and the :code:`pulp registry` on the seed.
The steps will assume that an infra-vm will be used for the purpose of hosting the runners.
Copy link
Member

Choose a reason for hiding this comment

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

I'd personally be in favor of adding a default config to our base environment which has some standard settings for cpus, memory, disk, runner name etc. Maybe we could even pre-configure the network interfaces to some extent

GitLab Pipelines
----------------

1. Edit :code:`${KAYOBE_CONFIG_PATH}/inventory/group_vars/gitlab-writer/writer.yml` in the base configuration making the appropriate changes to your deployments specific needs. See documentation for `stackhpc.kayobe_workflows.gitlab <https://github.com/stackhpc/ansible-collection-kayobe-workflows/tree/main/roles/gitlab>`__.
Copy link
Member

Choose a reason for hiding this comment

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

making the appropriate changes to your deployments specific needs

This is a bit vague. I think a lot of this can be given defaults here in SKC.

We should have a default writer.yml with:

gitlab_output_directory: $KAYOBE_CONFIG_PATH/../../.gitlab/

gitlab_registry: "{{ pulp_url }}"

gitlab_openstack_release: "{{ openstack_release }}"

and then just tell people to set gitlab_kayobe_environments:

Co-authored-by: Tom Clark <[email protected]>
Co-authored-by: Alex-Welsh <[email protected]>
@jackhodgkiss jackhodgkiss force-pushed the add-gitlab-kayobe-automation branch from 43071a0 to 1ae7397 Compare February 12, 2025 16:30
@jackhodgkiss jackhodgkiss force-pushed the add-gitlab-kayobe-automation branch from 1ae7397 to f3b4fde Compare February 18, 2025 10:06
@jackhodgkiss jackhodgkiss force-pushed the add-gitlab-kayobe-automation branch from d4d982a to 4d76e84 Compare February 18, 2025 10:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ansible Ansible playbooks documentation Improvements or additions to documentation size: l
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants