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

feat: add ansible execution environment for playbooks #806

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

cardoe
Copy link
Contributor

@cardoe cardoe commented Mar 27, 2025

This creates an ansible based container that has ansible-runner as the executor inside which can then be loaded with playbooks and roles so that we can have a consistent way to configure different parts of the system or react to events in the system and execute a series of steps. To provide a consistent way to configure the overall system and react to events in the system. Some areas where this might be useful is for OpenStack Helm has a bootstrap bash script that executes on deployment. This is a big hardcoded blob and will be easier to be configurable via ansible.

@cardoe cardoe force-pushed the ansible-start branch 2 times, most recently from c30a353 to 8953184 Compare March 28, 2025 18:23
@cardoe cardoe marked this pull request as ready for review March 28, 2025 18:25
@cardoe cardoe force-pushed the ansible-start branch 4 times, most recently from 2ab114b to e26c3b0 Compare April 7, 2025 22:01
@cardoe cardoe marked this pull request as draft April 8, 2025 13:46
@cardoe cardoe force-pushed the ansible-start branch 7 times, most recently from eaa4a2d to 7ac048a Compare April 10, 2025 21:08
This creates an ansible based container that has ansible-runner as the
executor inside which can then be loaded with playbooks and roles so
that we can have a consistent way to configure different parts of the
system or react to events in the system and execute a series of steps.
To provide a consistent way to configure the overall system and react to
events in the system. Some areas where this might be useful is for
OpenStack Helm has a bootstrap bash script that executes on deployment.
This is a big hardcoded blob and will be easier to be configurable via
ansible.
@cardoe cardoe force-pushed the ansible-start branch 6 times, most recently from d59b802 to 0a050b6 Compare April 10, 2025 21:47
cardoe added 2 commits April 10, 2025 16:50
The current keystone bootstrap is a bash script which makes it hard to
ensure that everything has been setup. By making it Ansible we can
ensure that things are consistent. Unfortunately the openstack's role
module does not support cross-domain or inherited like the CLI does so
this hacks around it with ansible.builtin.command that then needs some
hoops to avoid lint errors. Bump the keystone chart version which fixes
volume mounts so that our inventory can be mounted into the bootstrap
container.
This value is not used anywhere.
@cardoe cardoe requested a review from skrobul April 10, 2025 21:55
@cardoe
Copy link
Contributor Author

cardoe commented Apr 10, 2025

So this would require a ConfigMap in the openstack namespace called ansible-inventory with a key of hosts.yaml to exist. The contents would be something like:

all:
    vars:
        keystone_bootstrap_dex_url: "https://dex.dns.zone"

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.

2 participants