Skip to content

Add playbooks for SKMO#3684

Closed
vakwetu wants to merge 1 commit intoopenstack-k8s-operators:mainfrom
vakwetu:add_skmo
Closed

Add playbooks for SKMO#3684
vakwetu wants to merge 1 commit intoopenstack-k8s-operators:mainfrom
vakwetu:add_skmo

Conversation

@vakwetu
Copy link
Copy Markdown
Contributor

@vakwetu vakwetu commented Feb 13, 2026

Add multi-namespace SKMO scenario and playbooks
Add support for Shared Keystone Multi-region OpenStack (SKMO)
deployments with cross-region Barbican keystone listener:

Playbooks:

  • prepare-leaf.yaml: Pre-stage hook that creates a TransportURL CR
    in the central region for the leaf's barbican-keystone-listener,
    copies the generated secret to the leaf namespace, extracts
    rootca-internal CA cert from central and adds it to the leaf's
    custom-ca-certs bundle, and waits for central Keystone and
    openstackclient readiness with retry logic
  • configure-leaf-listener.yaml: Post-stage hook that patches the
    leaf OpenStackControlPlane with the cross-region transport_url
    for the barbican-keystone-listener
  • trust-leaf-ca.yaml: Post-stage hook that extracts the leaf
    region's rootca-public and rootca-internal CA certs and adds
    them to the central region's custom-ca-certs bundle
  • ensure-central-ca-bundle.yaml: Ensures the central CA bundle
    secret exists before the leaf control plane deployment

Scenario:

  • va-multi-skmo.yml reproducer scenario configuration
  • multi-namespace-skmo architecture scenario symlink

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Feb 13, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign bshewale for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@softwarefactory-project-zuul
Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/b7e9a45c2dc540e683237f9d199a301c

✔️ openstack-k8s-operators-content-provider SUCCESS in 2h 01m 57s
✔️ podified-multinode-edpm-deployment-crc SUCCESS in 1h 18m 44s
cifmw-crc-podified-edpm-baremetal RETRY_LIMIT in 27m 33s
✔️ cifmw-crc-podified-edpm-baremetal-minor-update SUCCESS in 1h 49m 08s
✔️ noop SUCCESS in 0s
✔️ cifmw-pod-ansible-test SUCCESS in 9m 04s
✔️ cifmw-pod-pre-commit SUCCESS in 8m 26s

@softwarefactory-project-zuul
Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/9a0c3d521a444791a9cb4da2cf7cedca

✔️ openstack-k8s-operators-content-provider SUCCESS in 1h 15m 25s
podified-multinode-edpm-deployment-crc FAILURE in 56m 51s
cifmw-crc-podified-edpm-baremetal FAILURE in 1h 01m 47s
cifmw-crc-podified-edpm-baremetal-minor-update FAILURE in 58m 54s
✔️ noop SUCCESS in 0s
✔️ cifmw-pod-ansible-test SUCCESS in 8m 59s
✔️ cifmw-pod-pre-commit SUCCESS in 8m 32s

@softwarefactory-project-zuul
Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/17da5110aa71420dbf164b2d3651f1bf

✔️ openstack-k8s-operators-content-provider SUCCESS in 2h 27m 13s
✔️ podified-multinode-edpm-deployment-crc SUCCESS in 1h 23m 03s
✔️ cifmw-crc-podified-edpm-baremetal SUCCESS in 1h 30m 14s
cifmw-crc-podified-edpm-baremetal-minor-update FAILURE in 2h 12m 02s
✔️ cifmw-pod-zuul-files SUCCESS in 5m 00s
✔️ noop SUCCESS in 0s
✔️ cifmw-pod-ansible-test SUCCESS in 8m 13s
✔️ cifmw-pod-k8s-snippets-source SUCCESS in 4m 37s
✔️ cifmw-pod-pre-commit SUCCESS in 8m 42s
✔️ cifmw-architecture-validate-hci SUCCESS in 4m 19s
✔️ cifmw-molecule-ci_gen_kustomize_values SUCCESS in 5m 56s

@softwarefactory-project-zuul
Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/2382ae10dbf24bc185e36fba76f1ffc5

✔️ openstack-k8s-operators-content-provider SUCCESS in 1h 35m 34s
✔️ podified-multinode-edpm-deployment-crc SUCCESS in 1h 21m 39s
cifmw-crc-podified-edpm-baremetal RETRY_LIMIT in 14m 38s
cifmw-crc-podified-edpm-baremetal-minor-update RETRY_LIMIT in 14m 22s
✔️ cifmw-pod-zuul-files SUCCESS in 6m 58s
✔️ noop SUCCESS in 0s
✔️ cifmw-pod-ansible-test SUCCESS in 10m 22s
✔️ cifmw-pod-k8s-snippets-source SUCCESS in 5m 25s
✔️ cifmw-pod-pre-commit SUCCESS in 11m 33s
✔️ cifmw-architecture-validate-hci SUCCESS in 4m 52s
✔️ cifmw-molecule-ci_gen_kustomize_values SUCCESS in 5m 11s

@vakwetu vakwetu requested review from abays and fultonj March 12, 2026 14:20
vakwetu added a commit to vakwetu/architecture that referenced this pull request Mar 12, 2026
Configure the multi-namespace SKMO scenario with:
- SKMO-specific control-plane kustomization for the central region
  with barbican-keystone-listener pool_name and RabbitMQ memory
  reduction (4Gi -> 2Gi) for compact clusters
- Barbican keystone listener pool_name configuration for both
  central (regionOne) and leaf (regionTwo) regions
- Automation stages updated to reference SKMO-specific paths
- Post-stage hook for populating cross-region transport URL
- Wait conditions adjusted for parallel deployment
- Correct keystone endpoint values for leaf region
- CA trust configuration between central and leaf regions
- Symlink net-env for SKMO to reuse multi-namespace networking

Depends-On: openstack-k8s-operators/ci-framework#3684
Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
vakwetu pushed a commit to vakwetu/architecture that referenced this pull request Mar 20, 2026
Configure the multi-namespace SKMO scenario with:
- SKMO-specific control-plane kustomization for the central region
  with barbican-keystone-listener pool_name and RabbitMQ memory
  reduction (4Gi -> 2Gi) for compact clusters
- Barbican keystone listener pool_name configuration for both
  central (regionOne) and leaf (regionTwo) regions
- Automation stages updated to reference SKMO-specific paths
- Post-stage hook for populating cross-region transport URL
- Wait conditions adjusted for parallel deployment
- Correct keystone endpoint values for leaf region
- CA trust configuration between central and leaf regions
- Symlink net-env for SKMO to reuse multi-namespace networking

Depends-On: openstack-k8s-operators/ci-framework#3684
Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
vakwetu added a commit to vakwetu/architecture that referenced this pull request Mar 20, 2026
Configure the multi-namespace SKMO scenario with:
- SKMO-specific control-plane kustomization for the central region
  with barbican-keystone-listener pool_name and RabbitMQ memory
  reduction (4Gi -> 2Gi) for compact clusters
- Barbican keystone listener pool_name configuration for both
  central (regionOne) and leaf (regionTwo) regions
- Automation stages updated to reference SKMO-specific paths
- Post-stage hook for populating cross-region transport URL
- Wait conditions adjusted for parallel deployment
- Correct keystone endpoint values for leaf region
- CA trust configuration between central and leaf regions
- Symlink net-env for SKMO to reuse multi-namespace networking

Depends-On: openstack-k8s-operators/ci-framework#3684
Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
vakwetu pushed a commit to vakwetu/architecture that referenced this pull request Mar 23, 2026
Configure the multi-namespace SKMO scenario with:
- SKMO-specific control-plane kustomization for the central region
  with barbican-keystone-listener pool_name and RabbitMQ memory
  reduction (4Gi -> 2Gi) for compact clusters
- Barbican keystone listener pool_name configuration for both
  central (regionOne) and leaf (regionTwo) regions
- Automation stages updated to reference SKMO-specific paths
- Post-stage hook for populating cross-region transport URL
- Wait conditions adjusted for parallel deployment
- Correct keystone endpoint values for leaf region
- CA trust configuration between central and leaf regions
- Symlink net-env for SKMO to reuse multi-namespace networking

Depends-On: openstack-k8s-operators/ci-framework#3684
Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
vakwetu added a commit to vakwetu/architecture that referenced this pull request Mar 23, 2026
Configure the multi-namespace SKMO scenario with:
- SKMO-specific control-plane kustomization for the central region
  with barbican-keystone-listener pool_name and RabbitMQ memory
  reduction (4Gi -> 2Gi) for compact clusters
- Barbican keystone listener pool_name configuration for both
  central (regionOne) and leaf (regionTwo) regions
- Automation stages updated to reference SKMO-specific paths
- Post-stage hook for populating cross-region transport URL
- Wait conditions adjusted for parallel deployment
- Correct keystone endpoint values for leaf region
- CA trust configuration between central and leaf regions
- Symlink net-env for SKMO to reuse multi-namespace networking

Depends-On: openstack-k8s-operators/ci-framework#3684
Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
vakwetu added a commit to vakwetu/architecture that referenced this pull request Mar 23, 2026
…ne stage

hook_controlplane_config.yml now directly patches the OSCP (Step 6),
which requires the CR to exist. Moving the hook from pre_stage_run to
post_stage_run for stage 5 (control-plane) ensures the OSCP has been
created by the kustomize deploy before the hook tries to patch it.

Bootstrap Keycloak remains in pre_stage_run so that the
ingress-operator-ca.crt is available when the hook runs post-deploy.

Depends-On: openstack-k8s-operators/ci-framework#3684

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
Made-with: Cursor
Copy link
Copy Markdown
Contributor

@fultonj fultonj left a comment

Choose a reason for hiding this comment

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

Based on what I've seen from reviews of others on the ci-framwork team,
I think hooks/playbooks/skmo is a better place for the playbooks than playbooks/skmo.

Comment thread playbooks/skmo/prepare-leaf.yaml Outdated
args:
executable: /bin/bash

- name: Create or append leaf CA bundle secret
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The ansible shell piping into python caught my attention. I think it can be avoided. I showed lines 134-169 to Claude Code and it suggested something like the following as an alternative.

  - name: Get existing CA bundle if present                                                                                                                                                                                             
    kubernetes.core.k8s_info:                                                                                                                                                                                                           
      api_version: v1                                                                                                                                                                                                                   
      kind: Secret                                                                                                                                                                                                                      
      namespace: "{{ leaf_namespace }}"                                                                                                                                                                                                 
      name: "{{ ca_bundle_secret_name }}"                                                                                                                                                                                               
    register: _existing_bundle                                                                                                                                                                                                          
                                                                                                                                                                                                                                        
  - name: Get central rootca certs                                                                                                                                                                                                      
    kubernetes.core.k8s_info:                                                                                                                                                                                                           
      api_version: v1                                                                                                                                                                                                                   
      kind: Secret                                                                                                                                                                                                                      
      namespace: "{{ central_namespace }}"                                                                                                                                                                                              
      name: "{{ item }}"                                                                                                                                                                                                                
    register: _central_certs                                                                                                                                                                                                            
    loop:                                                                                                                                                                                                                               
      - "{{ central_rootca_secret }}"                     
      - "{{ central_rootca_internal_secret }}"            

  - name: Create or update leaf CA bundle secret          
    kubernetes.core.k8s:                                  
      state: present                                      
      definition:                                         
        apiVersion: v1                                    
        kind: Secret                                      
        metadata:                                         
          name: "{{ ca_bundle_secret_name }}"             
          namespace: "{{ leaf_namespace }}"               
        data: "{{ (_existing_bundle.resources[0].data | default({})) | combine({                                    
          'skmo-central-rootca.crt': _central_certs.results[0].resources[0].data['tls.crt'],                        
          'skmo-central-rootca-internal.crt': _central_certs.results[1].resources[0].data['tls.crt']                
        }) }}"   

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fixed in latest

args:
executable: /bin/bash

- name: Copy transport URL secret to leaf namespace
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Could you try making this work using the following (suggested by Claude code)?

  - name: Get transport URL secret from central namespace 
    kubernetes.core.k8s_info:                             
      api_version: v1                                     
      kind: Secret                                        
      namespace: "{{ central_namespace }}"                
      name: "{{ leaf_transport_url_name_secret }}"        
    register: _transport_secret                           

  - name: Copy transport URL secret to leaf namespace     
    kubernetes.core.k8s:                                  
      state: present                                      
      definition: 
        apiVersion: v1                                    
        kind: Secret                                      
        metadata:                                         
          name: "{{ leaf_transport_url_secret_copy }}"    
          namespace: "{{ leaf_namespace }}"               
        type: "{{ _transport_secret.resources[0].type }}" 
        data: "{{ _transport_secret.resources[0].data }}" 

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fixed in latest

Comment thread playbooks/skmo/trust-leaf-ca.yaml Outdated
ansible.builtin.set_fact:
central_ca_bundle_secret_name: "{{ skmo_values.data.centralCaBundleSecretName }}"

- name: Create or append central CA bundle secret
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Could you try replacing this task with this instead (again from Claude)?

  - name: Get existing central CA bundle if present
    kubernetes.core.k8s_info:                                                                                                                                                                                                           
      api_version: v1                                                                                                                                                                                                                 
      kind: Secret
      namespace: "{{ central_namespace }}"
      name: "{{ central_ca_bundle_secret_name }}"
    register: _existing_bundle

  - name: Get leaf rootca certs
    kubernetes.core.k8s_info:
      api_version: v1
      kind: Secret
      namespace: "{{ leaf_namespace }}"
      name: "{{ item }}"
    register: _leaf_certs                                                                                                                                                                                                               
    loop:                                                                                                                                                                                                                               
      - "{{ leaf_rootca_secret }}"                                                                                                                                                                                                      
      - "{{ leaf_rootca_internal_secret }}"                                                                                                                                                                                             
                                                                                                                                                                                                                                        
  - name: Create or update central CA bundle secret                                                                                                                                                                                     
    kubernetes.core.k8s:                                                                                                                                                                                                                
      state: present                                                                                                                                                                                                                    
      definition: 
        apiVersion: v1                                                                                                                                                                                                                  
        kind: Secret                                                                                                                                                                                                                    
        metadata:                                                                                                                                                                                                                       
          name: "{{ central_ca_bundle_secret_name }}"                                                                                                                                                                                   
          namespace: "{{ central_namespace }}"                                                                                                                                                                                          
        data: "{{ (_existing_bundle.resources[0].data | default({})) | combine({                                                                                                                                                        
          'skmo-leaf-rootca.crt': _leaf_certs.results[0].resources[0].data['tls.crt'],                                                                                                                                                  
          'skmo-leaf-rootca-internal.crt': _leaf_certs.results[1].resources[0].data['tls.crt']                                                                                                                                          
        }) }}"   

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fixed in latest

…ooks

Add support for Shared Keystone Multi-region OpenStack (SKMO)
deployments with cross-region Barbican keystone listener:

Playbooks (in hooks/playbooks/skmo/):
- prepare-leaf.yaml: Pre-stage hook that creates a TransportURL CR
  in the central region for the leaf's barbican-keystone-listener,
  copies the generated secret to the leaf namespace, extracts
  rootca-internal CA cert from central and adds it to the leaf's
  custom-ca-certs bundle, and waits for central Keystone and
  openstackclient readiness with retry logic
- configure-leaf-listener.yaml: Post-stage hook that patches the
  leaf OpenStackControlPlane with the cross-region transport_url
  for the barbican-keystone-listener
- trust-leaf-ca.yaml: Post-stage hook that extracts the leaf
  region's rootca-public and rootca-internal CA certs and adds
  them to the central region's custom-ca-certs bundle
- ensure-central-ca-bundle.yaml: Ensures the central CA bundle
  secret exists before the leaf control plane deployment

Scenario:
- va-multi-skmo.yml reproducer scenario configuration
- multi-namespace-skmo architecture scenario symlink

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
Made-with: Cursor
vakwetu pushed a commit to vakwetu/architecture that referenced this pull request Mar 23, 2026
Configure the multi-namespace SKMO scenario with:
- SKMO-specific control-plane kustomization for the central region
  with barbican-keystone-listener pool_name and RabbitMQ memory
  reduction (4Gi -> 2Gi) for compact clusters
- Barbican keystone listener pool_name configuration for both
  central (regionOne) and leaf (regionTwo) regions
- Automation stages updated to reference SKMO-specific paths
- Post-stage hooks for cross-region CA trust, transport URL setup,
  and barbican-keystone-listener configuration
- Wait conditions adjusted for parallel deployment
- Correct keystone endpoint values for leaf region
- CA trust configuration between central and leaf regions
- Symlink net-env for SKMO to reuse multi-namespace networking
- README documenting the SKMO scenario and deployment stages

Depends-On: openstack-k8s-operators/ci-framework#3684

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
@vakwetu
Copy link
Copy Markdown
Contributor Author

vakwetu commented Mar 23, 2026

addressed comments - added WIP label until testing is done.

vakwetu added a commit to vakwetu/architecture that referenced this pull request Mar 23, 2026
…ne stage

hook_controlplane_config.yml now directly patches the OSCP (Step 6),
which requires the CR to exist. Moving the hook from pre_stage_run to
post_stage_run for stage 5 (control-plane) ensures the OSCP has been
created by the kustomize deploy before the hook tries to patch it.

Bootstrap Keycloak remains in pre_stage_run so that the
ingress-operator-ca.crt is available when the hook runs post-deploy.

Depends-On: openstack-k8s-operators/ci-framework#3684

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
Made-with: Cursor
softwarefactory-project-zuul Bot pushed a commit to openstack-k8s-operators/architecture that referenced this pull request Mar 27, 2026
Configure the multi-namespace SKMO scenario with:
- SKMO-specific control-plane kustomization for the central region
  with barbican-keystone-listener pool_name and RabbitMQ memory
  reduction (4Gi -> 2Gi) for compact clusters
- Barbican keystone listener pool_name configuration for both
  central (regionOne) and leaf (regionTwo) regions
- Automation stages updated to reference SKMO-specific paths
- Post-stage hooks for cross-region CA trust, transport URL setup,
  and barbican-keystone-listener configuration
- Wait conditions adjusted for parallel deployment
- Correct keystone endpoint values for leaf region
- CA trust configuration between central and leaf regions
- Symlink net-env for SKMO to reuse multi-namespace networking
- README documenting the SKMO scenario and deployment stages

Depends-On: openstack-k8s-operators/ci-framework#3684

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
softwarefactory-project-zuul Bot pushed a commit to openstack-k8s-operators/architecture that referenced this pull request Mar 27, 2026
…ne stage

hook_controlplane_config.yml now directly patches the OSCP (Step 6),
which requires the CR to exist. Moving the hook from pre_stage_run to
post_stage_run for stage 5 (control-plane) ensures the OSCP has been
created by the kustomize deploy before the hook tries to patch it.

Bootstrap Keycloak remains in pre_stage_run so that the
ingress-operator-ca.crt is available when the hook runs post-deploy.

Depends-On: openstack-k8s-operators/ci-framework#3684

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
Made-with: Cursor
@vakwetu
Copy link
Copy Markdown
Contributor Author

vakwetu commented Mar 27, 2026

superseded by #3766

@vakwetu vakwetu closed this Mar 27, 2026
eduolivares pushed a commit to eduolivares/architecture that referenced this pull request Apr 9, 2026
Configure the multi-namespace SKMO scenario with:
- SKMO-specific control-plane kustomization for the central region
  with barbican-keystone-listener pool_name and RabbitMQ memory
  reduction (4Gi -> 2Gi) for compact clusters
- Barbican keystone listener pool_name configuration for both
  central (regionOne) and leaf (regionTwo) regions
- Automation stages updated to reference SKMO-specific paths
- Post-stage hooks for cross-region CA trust, transport URL setup,
  and barbican-keystone-listener configuration
- Wait conditions adjusted for parallel deployment
- Correct keystone endpoint values for leaf region
- CA trust configuration between central and leaf regions
- Symlink net-env for SKMO to reuse multi-namespace networking
- README documenting the SKMO scenario and deployment stages

Depends-On: openstack-k8s-operators/ci-framework#3684

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
eduolivares pushed a commit to eduolivares/architecture that referenced this pull request Apr 9, 2026
…ne stage

hook_controlplane_config.yml now directly patches the OSCP (Step 6),
which requires the CR to exist. Moving the hook from pre_stage_run to
post_stage_run for stage 5 (control-plane) ensures the OSCP has been
created by the kustomize deploy before the hook tries to patch it.

Bootstrap Keycloak remains in pre_stage_run so that the
ingress-operator-ca.crt is available when the hook runs post-deploy.

Depends-On: openstack-k8s-operators/ci-framework#3684

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Ade Lee <alee@redhat.com>
Made-with: Cursor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants