Repository navigation
feat(dual-stack): add IPv6 hostname-based networking across main, repo_manager, and image_build_manager - #5954
Rohith-Ravut wants to merge 5 commits into
Conversation
…rification failures (dell#5952) * fix(image_build_manager): add missing PowerScale validation message variables The powerscale_check.yml task references powerscale_validation_fail_msg and powerscale_unreachable_msg in fail_msg directives, but neither variable was defined in validate_build_runtime/vars/main.yml. Ansible evaluates fail_msg expressions during task arg finalization before checking the 'when' condition. When provider is set to 'powerscale', the assert task fails with: "Error while resolving value for 'fail_msg': 'powerscale_validation_fail_msg' is undefined" This commit adds both missing variable definitions so the validation task can execute properly and provide meaningful error messages. Signed-off-by: Rohith Ravut <rohith.ravut@dellteam.com> * fix(image_build_manager): create .s3cfg for PowerScale and fix cleanup When s3_configurations.provider is 'powerscale', the deploy_minio role skips the entire MinIO deployment block including s3_bucket.yml which installs s3cmd and renders /root/.s3cfg. The build_os_images role uses s3cmd to verify uploads regardless of provider, so without .s3cfg the verification silently returns 0 matches and fails. Changes: - Add EPEL GPG key import, EPEL release install, s3cmd install, and .s3cfg rendering for the PowerScale provider path in deploy_minio - Remove the PowerScale provider guard from cleanup_s3cmd.yml so .s3cfg is cleaned up for both providers - Add s3cmd_config variable to deploy_minio/vars/main.yml Signed-off-by: Rohith Ravut <rohith.ravut@dellteam.com> --------- Signed-off-by: Rohith Ravut <rohith.ravut@dellteam.com> Co-authored-by: Abhishek S A <abhishek.sa3@dell.com>
…o_manager, and image_build_manager Enable dual-stack (IPv4 + IPv6) connectivity using hostname-based service URLs across three domains: Main domain: - Add SYSTEM_ADMIN_NIC_IPV6 optional env var in omnia.env - Derive SYSTEM_OIM_HOSTNAME (FQDN) in omnia.sh and omnia-cli - Validate IPv6 address is on a local interface - Update profile drop-in and activate-omnia.sh templates Repo Manager domain: - Switch all Pulp URLs from raw IP to pulp_endpoint_authority (hostname) - Add env-var fallback for hostname and IPv6 from omnia.env - Dynamic TLS certificate SANs (hostname + IPv6 when configured) - socat IPv6 proxy for Pulp (pulp_ipv6_proxy.service.j2) - Update Python module generate_local_repo_access.py Image Build Manager domain: - Switch all S3/MinIO endpoints from admin_nic_ip to oim_hostname - Switch registry endpoints to oim_hostname - Bind MinIO to admin NIC only (not all interfaces) - socat IPv6 proxy for MinIO (minio_ipv6_proxy.service.j2) - Add IPv6 validation in validate_system_environment.py - Update cleanup to handle IPv6 proxy teardown Design: - Hostname over IP for all client-facing URLs - Podman binds to IPv4; socat proxies bridge IPv6 to IPv4 - Fully backward compatible (opt-in via SYSTEM_ADMIN_NIC_IPV6) - Single source of truth in omnia.env Signed-off-by: Rohith Ravut <rohith.ravut@dellteam.com>
# Conflicts: # src/image_build_manager/roles/deploy_minio/tasks/main.yml # src/image_build_manager/roles/validate_build_runtime/vars/main.yml
Compliance GateResult: 3 passed, 0 not passed (3 domain scope(s) checked; unchanged domains are skipped) Not checked (no changes in that domain): pipeline/pipeline, src/build_stream, src/discovery, src/orchestrator, src/telemetry, src/utils, svt/svt, test/build_stream, test/discovery, test/image_build_manager, test/main, test/orchestrator, test/repo_manager, test/telemetry, test/utils src/image_build_manager: PASSED
src/main: PASSED
src/repo_manager: PASSED
|
Secure Code ReviewAdvisory only: this check never blocks the PR. It scans the lines added by this PR against secure-coding rules derived from recent security fixes in this repository. Result: 16 passed, 1 failed (43 file(s) scanned) Checklist
Failed checks - detailsSEC-06 No unsafe Jinja lookups - 5 finding(s)Guideline: Avoid lookup('pipe'|'env'), eval-style filters and template of untrusted input; load user YAML as literal data (no Jinja evaluation).
Manual review focus (based on changed files)
Findings are heuristic; reviewers should confirm each one. Suppress a justified finding with a |
ansible-lint no-handler rule: tasks with 'when: .changed' should use notify + handlers instead. Replaced inline daemon_reload tasks with notify on the existing 'reload pulp systemd' handler, followed by flush_handlers to ensure systemd is reloaded before the next task. Signed-off-by: Rohith Ravut <rohith.ravut@dellteam.com>
Signed-off-by: Rohith Ravut <rohith.ravut@dellteam.com>
Description of the Solution
Enables dual-stack (IPv4 + IPv6) connectivity across three Omnia domains using hostname-based service URLs and socat IPv6 proxies. All changes are backward compatible -- IPv6 is activated only by setting
SYSTEM_ADMIN_NIC_IPV6inomnia.env.Design
SYSTEM_OIM_HOSTNAME(e.g.omniacp.omnia.test). DNS resolves to both A (IPv4) and AAAA (IPv6) records.PublishPortbinds toSYSTEM_ADMIN_NIC_IPV4. Podman/netavark only generates IPv4 DNAT rules -- IPv6PublishPortaccepts connections at the socket but never forwards them into containers.SYSTEM_ADMIN_NIC_IPV6, behavior is identical to the original IPv4-only code. Zero breaking changes.omnia.env. Downstream domains inherit them.Related Issue
Changes
Domain 1: Main (6 files, 76 insertions, 11 deletions)
src/main/omnia.envSYSTEM_ADMIN_NIC_IPV6optional variablesrc/main/omnia.shSYSTEM_OIM_HOSTNAMEfrom${SYSTEM_HOSTNAME}.${SYSTEM_DOMAIN_NAME}. Validates IPv6 is on a local interface. Exports both new variables.src/main/omnia-clisrc/main/docs/omnia-env.mdsrc/main/docs/omnia-setup.mdsrc/main/README.mdDomain 2: Repo Manager (14 modified + 1 new file, 173 insertions, 31 deletions)
input/repo_manager_endpoint_config.ymlpulp_server_hostnameandpulp_server_ipv6fieldsroles/pulp_validation/tasks/read_endpoint_config.ymlSYSTEM_OIM_HOSTNAME, IPv6 fromSYSTEM_ADMIN_NIC_IPV6. Derivespulp_endpoint_authority.roles/pulp_validation/vars/main.ymlpulp_endpoint_authorityroles/deploy_pulp/vars/main.ymlroles/deploy_pulp/tasks/prepare_tls.ymlopenssl x509 -checkhost. CN prefers hostname. Auto-regenerates cert if hostname SAN missing.roles/deploy_pulp/tasks/deploy_container_https.ymlroles/deploy_pulp/templates/pulp_ipv6_proxy.service.j2roles/parse_and_download/tasks/*.yml(2 files)pulp_endpoint_authorityplaybooks/repo_operations/*.yml(3 files)pulp_endpoint_authority, pass hostnameplaybooks/deploy/deploy_pulp.ymlpulp_endpoint_authorityplugins/modules/generate_local_repo_access.pypulp_server_hostnameparameterDomain 3: Image Build Manager (19 modified + 1 new file)
roles/image_build_setup/tasks/load_config.ymlSYSTEM_ADMIN_NIC_IPV6and derivesoim_hostnamefromSYSTEM_OIM_HOSTNAMEroles/deploy_minio/vars/main.ymladmin_nic_ipv6,oim_hostname,cluster_boot_hostname,s3cmd_configvariablesroles/deploy_minio/templates/minio/minio.service.j2admin_nic_iponly (was all interfaces)roles/deploy_minio/templates/s3/s3cfg.j2host_baseusesoim_hostnameroles/deploy_minio/tasks/main.ymlroles/deploy_minio/tasks/policy_update.ymlcluster_boot_hostnameroles/deploy_minio/templates/minio/minio_ipv6_proxy.service.j2roles/build_os_images/vars/main.ymlregistry_hostusingoim_hostnameroles/build_os_images/tasks/configure_registry.ymloim_hostnamefor registryroles/build_os_images/tasks/build_image_common_x86_64.ymloim_hostnameroles/build_os_images/tasks/build_image_common_aarch64.ymloim_hostnameroles/build_os_images/templates/build_status.yml.j2oim_hostnameroles/deploy_registry/tasks/main.ymloim_hostnameroles/prepare_aarch64_node/tasks/*.yml(2 files)oim_hostnameroles/cleanup_build_artifacts/tasks/cleanup_minio.ymlroles/cleanup_build_artifacts/tasks/cleanup_images.ymlroles/cleanup_build_artifacts/vars/main.ymloim_hostname,admin_nic_ipv6plugins/modules/validate_system_environment.pyTesting
curl -4 https://omniacp.omnia.test:2225)curl -6 https://omniacp.omnia.test:2225)curl -4 http://omniacp.omnia.test:9000)curl -6 http://omniacp.omnia.test:9000)curl http://omniacp.omnia.test:5000/v2/)IP:10.41.12.150,DNS:omniacp.omnia.test,IP:fd00::150,DNS:pulp,DNS:localhostss -tlnp)pulp-ipv6-proxy.serviceandminio-ipv6-proxy.serviceactive (running)SYSTEM_ADMIN_NIC_IPV6, behavior identical to originalyaml.safe_loadBackward Compatibility
SYSTEM_ADMIN_NIC_IPV6.Summary
pulp_ipv6_proxy.service.j2,minio_ipv6_proxy.service.j2)