From b4414bda2dd6d4c30adf86648e7eb0c9cd26922b Mon Sep 17 00:00:00 2001 From: rabi Date: Thu, 13 Aug 2026 11:41:57 +0530 Subject: [PATCH 1/2] Fix docs job which is doing spellcheck docs job is failing at the moment. Signed-off-by: rabi --- docs/dictionary/en-custom.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/dictionary/en-custom.txt b/docs/dictionary/en-custom.txt index 984bc59f5..2d4db5fdb 100644 --- a/docs/dictionary/en-custom.txt +++ b/docs/dictionary/en-custom.txt @@ -224,6 +224,7 @@ epel epyc etcd eth +evallesp extraRPMs extraimages ezzmy @@ -635,6 +636,7 @@ tcib tdciagigtlesa tempestconf testcases +testconfig testenv testproject timestamper @@ -675,6 +677,7 @@ v3oidcauthcode v3oidcclientcredentials v3oidcdeviceauthz v3oidcpassword +vallespi vbibob vbmc vcgvuc From 740856df7363275ee8f10ac39f933d34fec02f63 Mon Sep 17 00:00:00 2001 From: rabi Date: Wed, 12 Aug 2026 18:23:23 +0530 Subject: [PATCH 2/2] [multiple] Discover cinder and manila backend keys Resolve cinder volume and manila share image map keys from the live OpenStackControlPlane CR when callers do not provide them explicitly. This avoids emitting misleading default backend names and keeps backend-keyed customContainerImages aligned with the deployed control plane. Signed-off-by: rabi --- .../tasks/kustomize_and_deploy.yml | 62 +++++++++++++------ roles/update_containers/README.md | 11 +++- roles/update_containers/defaults/main.yml | 7 +-- 3 files changed, 55 insertions(+), 25 deletions(-) diff --git a/roles/edpm_prepare/tasks/kustomize_and_deploy.yml b/roles/edpm_prepare/tasks/kustomize_and_deploy.yml index caa147c7e..d1c800681 100644 --- a/roles/edpm_prepare/tasks/kustomize_and_deploy.yml +++ b/roles/edpm_prepare/tasks/kustomize_and_deploy.yml @@ -28,25 +28,6 @@ cifmw_update_containers_tag: "{{ content_provider_dlrn_md5_hash }}" cifmw_update_containers_openstack: true -- name: Prepare OpenStackVersion CR - when: >- - (cifmw_prepare_openstackversion | bool) and - ((cifmw_update_containers_edpm_image_url is defined and - cifmw_update_containers_openstack is defined and - cifmw_update_containers_openstack | bool) or - (cifmw_update_containers_ansibleee_image_url is defined) or - (cifmw_update_containers_openstack is defined and - cifmw_update_containers_openstack | bool) or - (cifmw_update_containers_watcher is defined and - cifmw_update_containers_watcher | bool) or - (cifmw_update_containers_ceilometersgcoreImage is defined) or - (cifmw_update_containers_ceilometermysqldexporterImage is defined) or - (cifmw_update_containers_edpmpodmanexporterImage is defined)) - vars: - cifmw_update_containers_metadata: "{{ _ctlplane_name }}" - ansible.builtin.include_role: - name: update_containers - - name: Controlplane name kustomization ansible.builtin.set_fact: _ctlplane_name_kustomizations: @@ -98,6 +79,49 @@ ansible.builtin.debug: var: cifmw_edpm_prepare_crs_kustomize_result +# Runs after kustomize (so backends injected via kustomizations are visible) and +# before the OSCP apply (so the OpenStackVersion custom images are seeded first). +- name: Prepare OpenStackVersion CR + when: >- + (cifmw_prepare_openstackversion | bool) and + ((cifmw_update_containers_edpm_image_url is defined and + cifmw_update_containers_openstack is defined and + cifmw_update_containers_openstack | bool) or + (cifmw_update_containers_ansibleee_image_url is defined) or + (cifmw_update_containers_openstack is defined and + cifmw_update_containers_openstack | bool) or + (cifmw_update_containers_watcher is defined and + cifmw_update_containers_watcher | bool) or + (cifmw_update_containers_ceilometersgcoreImage is defined) or + (cifmw_update_containers_ceilometermysqldexporterImage is defined) or + (cifmw_update_containers_edpmpodmanexporterImage is defined)) + block: + - name: Derive cinder/manila backend names from the control plane CR + vars: + _ctlplane_spec: >- + {{ + ((lookup('file', cifmw_edpm_prepare_crs_kustomize_result.output_path) + | from_yaml_all | selectattr('kind', 'equalto', 'OpenStackControlPlane') + | map(attribute='spec') | list) + [{}]) | first + }} + ansible.builtin.set_fact: + cifmw_update_containers_cindervolumes: >- + {{ + (cifmw_update_containers_cindervolumes | default([])) + or (_ctlplane_spec.get('cinder', {}).get('template', {}).get('cinderVolumes', {}) | list) + }} + cifmw_update_containers_manilashares: >- + {{ + (cifmw_update_containers_manilashares | default([])) + or (_ctlplane_spec.get('manila', {}).get('template', {}).get('manilaShares', {}) | list) + }} + + - name: Generate the OpenStackVersion CR with custom images + vars: + cifmw_update_containers_metadata: "{{ _ctlplane_name }}" + ansible.builtin.include_role: + name: update_containers + - name: Apply the OpenStackControlPlane CR environment: KUBECONFIG: "{{ cifmw_openshift_kubeconfig }}" diff --git a/roles/update_containers/README.md b/roles/update_containers/README.md index 76c50b65e..fdeb05070 100644 --- a/roles/update_containers/README.md +++ b/roles/update_containers/README.md @@ -16,9 +16,9 @@ If apply, please explain the privilege escalation done in this role. * `cifmw_update_containers_name_prefix`: The container name prefix. Default to "openstack". * `cifmw_update_containers_org`: The container registry namespace to pull container from. Default to `{{ cifmw_default_container_image_namespace }}` (defined in group_vars/all.yml) * `cifmw_update_containers_tag`: The container tag. Default to `{{ cifmw_default_container_image_tag }}` (defined in group_vars/all.yml). -* `cifmw_update_containers_cindervolumes`: The names of the cinder volumes prefix. Default to `[]`. +* `cifmw_update_containers_cindervolumes`: The names of the cinder volume backends, used as keys under `customContainerImages.cinderVolumeImages`. Must match the backends in `OpenStackControlPlane.spec.cinder.template.cinderVolumes`. Default to `[]`. * `cifmw_update_containers_cindervolumes_extra`: Additional cinder volumes containers, meaning names and container URIs. Default to `{}`. -* `cifmw_update_containers_manilashares`: The names of the manila shares prefix. Default to `[]`. +* `cifmw_update_containers_manilashares`: The names of the manila share backends, used as keys under `customContainerImages.manilaShareImages`. Must match the backends in `OpenStackControlPlane.spec.manila.template.manilaShares`. Default to `[]`. * `cifmw_update_containers_agentimage`: Full Agent Image url for updating Agent Image. * `cifmw_update_containers_ceilometersgcoreImage`: Full Ceilometersgcore Image url for updating Ceilometersgcore Image. * `cifmw_update_containers_ceilometermysqldexporterImage`: Full Ceilometer mysqld_exporter Image url for updating Ceilometer mysqld_exporter Image. @@ -47,6 +47,13 @@ If apply, please explain the privilege escalation done in this role. name: update_containers ``` +When updating Cinder volume or Manila share images, the keys under +`customContainerImages.cinderVolumeImages` and +`customContainerImages.manilaShareImages` must match the backend names defined +in `OpenStackControlPlane`. Provide them via +`cifmw_update_containers_cindervolumes` / `cifmw_update_containers_manilashares`. +When empty, no per-backend image overrides are emitted. + ### 2 - Update Ansibleee container image ```yaml - hosts: all diff --git a/roles/update_containers/defaults/main.yml b/roles/update_containers/defaults/main.yml index 711530b2b..2593cc66f 100644 --- a/roles/update_containers/defaults/main.yml +++ b/roles/update_containers/defaults/main.yml @@ -19,6 +19,7 @@ # All variables within this role should have a prefix of "cifmw_update_containers" cifmw_update_containers: false +cifmw_update_containers_metadata: controlplane cifmw_update_containers_namespace: openstack cifmw_update_containers_base_dir: "{{ cifmw_basedir }}" cifmw_update_containers_dest_path: >- @@ -37,11 +38,9 @@ cifmw_update_containers_tag: "{{ cifmw_default_container_image_tag }}" cifmw_update_containers_name_prefix: "openstack" cifmw_update_containers_openstack: false cifmw_update_containers_rollback: false -cifmw_update_containers_cindervolumes: - - default +cifmw_update_containers_cindervolumes: [] cifmw_update_containers_cindervolumes_extra: {} -cifmw_update_containers_manilashares: - - default +cifmw_update_containers_manilashares: [] cifmw_update_containers_watcher: false # cifmw_update_containers_ansibleee_image_url: # cifmw_update_containers_edpm_image_url: