fdp_update_edpm
Role for updating OpenStack EDPM (Edge Data Plane Management) nodes with custom container images and host packages.
Description
This role provides a declarative approach to update EDPM nodes with:
Updates container images by patching OpenStackDataPlaneNodeSet CRs with new image references
Updates host packages by configuring
edpm_bootstrap_packagesandedpm_bootstrap_reposin the nodesetConfigures registry authentication with OpenShift service account tokens
Installs CA certificates for secure registry access
Optionally creates deployments to apply the changes to EDPM nodes
Key Features
Declarative approach: Only modifies Kubernetes CRs, doesn’t execute commands directly on EDPM nodes
Uses native EDPM capabilities: Leverages
edpm_bootstrapandedpm_podmanroles from edpm-ansibleSecure by default: Installs OpenShift CA certificates instead of using insecure registries
Flexible: Supports updating containers, packages, or both
Idempotent: Can be run multiple times safely
Requirements
OpenShift cluster with OpenStack operators installed
Access to
occommandOpenStackVersion CR with custom container images
Custom repository with updated packages (if updating host packages)
Role Variables
General Configuration
Variable |
Default |
Description |
|---|---|---|
|
|
OpenShift namespace |
|
|
NodeSet to update ( |
|
|
Show changes without applying |
Container Image Updates
Variable |
Default |
Description |
|---|---|---|
|
|
Enable container image updates |
|
|
External registry URL (auto-detected if empty) |
|
See defaults |
Mapping of image keys to EDPM variables |
Host Package Updates
Variable |
Default |
Description |
|---|---|---|
|
|
Enable host package updates |
|
|
REQUIRED Repository base URL |
|
|
Repository name |
|
See defaults |
List of packages to install/update |
Hypervisor Firewall Configuration
Variable |
Default |
Description |
|---|---|---|
|
|
Enable/disable hypervisor firewall setup for registry access |
|
|
Hostname or inventory name of the hypervisor where firewall rules will be configured via delegate_to |
|
|
Network interface on hypervisor connected to compute nodes (EDPM) |
|
|
Network interface on hypervisor connected to OpenShift/registry |
|
|
Compute nodes network CIDR (source for NAT) |
|
|
OpenShift/registry network CIDR (destination for NAT) |
Registry Configuration
Variable |
Default |
Description |
|---|---|---|
|
|
Install OpenShift CA certificate via bootstrap command |
|
|
Configure registry authentication |
Deployment Configuration
Variable |
Default |
Description |
|---|---|---|
|
|
Automatically create deployment |
|
|
Create separate deployment per nodeset |
|
|
Wait for deployment to complete |
|
|
Deployment timeout (seconds) |
|
See defaults |
Services to run in deployment |
Dependencies
None (uses native OpenStack Data Plane operators and edpm-ansible roles)
Example Playbook
Update both containers and packages
- hosts: localhost
roles:
- role: fdp_update_edpm
vars:
cifmw_fdp_update_edpm_namespace: openstack
cifmw_fdp_update_edpm_nodeset_name: openstack-edpm
cifmw_fdp_update_edpm_repo_baseurl: "http://example.com/repos/fdp-updates"
cifmw_fdp_update_edpm_packages:
- openvswitch3.5
- openvswitch-selinux-extra-policy
Update only containers
- hosts: localhost
roles:
- role: fdp_update_edpm
vars:
cifmw_fdp_update_edpm_packages_enabled: false
cifmw_fdp_update_edpm_containers_enabled: true
Update only packages
- hosts: localhost
roles:
- role: fdp_update_edpm
vars:
cifmw_fdp_update_edpm_containers_enabled: false
cifmw_fdp_update_edpm_packages_enabled: true
cifmw_fdp_update_edpm_repo_baseurl: "http://example.com/repos/updates"
Dry run (show changes without applying)
- hosts: localhost
roles:
- role: fdp_update_edpm
vars:
cifmw_fdp_update_edpm_dry_run: true
Custom network configuration
- hosts: localhost
roles:
- role: fdp_update_edpm
vars:
cifmw_fdp_update_compute_interface: "br-ex"
cifmw_fdp_update_registry_interface: "br-ocp"
cifmw_fdp_update_compute_network: "10.0.0.0/24"
cifmw_fdp_update_registry_network: "172.16.0.0/24"
How It Works
Validates parameters: Ensures required variables are set
Configures hypervisor firewall (if enabled): Sets up iptables rules to allow EDPM nodes to access the OpenShift registry
Fetches NodeSets: Gets OpenStackDataPlaneNodeSet CRs from the cluster
Fetches container images (if enabled): Gets custom images from OpenStackVersion CR
For each NodeSet:
Patches container image variables (e.g.,
edpm_ovn_controller_agent_image)Patches
edpm_bootstrap_packageswith packages to installPatches
edpm_bootstrap_reposwith custom repository configurationConfigures registry authentication (
edpm_container_registry_logins)Installs CA certificate via
edpm_bootstrap_command(if enabled)
Creates deployment (if enabled): Creates OpenStackDataPlaneDeployment CR
Waits for completion (if enabled): Monitors deployment until Ready
Architecture: Declarative vs Imperative
This role follows the declarative approach of Kubernetes/OpenStack:
Does NOT SSH to nodes and run
dnf installdirectlyDoes NOT SSH to nodes and run
systemctl restartdirectly[OK] Does patch NodeSet CRs with desired state
[OK] Does let OpenStack Data Plane Operator apply the changes
[OK] Does use native
edpm_bootstraprole for package installation[OK] Does use native
edpm_podmanrole for container management[OK] Does use
edpm_bootstrap_commandfor CA certificate installation
License
Apache 2.0