Fix missing local registry for baremetal with MIRROR_IMAGES - #1938
Fix missing local registry for baremetal with MIRROR_IMAGES#1938rebtoor wants to merge 1 commit into
Conversation
PR openshift-metal3#1922 added an early exit in 02_configure_host.sh for NODES_PLATFORM=baremetal, which skips setup_local_registry. This breaks environments that set NODES_PLATFORM=baremetal together with MIRROR_IMAGES=true (e.g. virtual-baremetal CI using sushy-emulator), because 04_setup_ironic.sh still attempts to mirror release images into the local registry at port 5000 and gets "connection refused". Add registry setup to the baremetal early-exit path: - If using podman registry: start it and create REGISTRY_CREDS via podman login (mirrors the pattern in the libvirt path) - If using quay registry: start it - If no registry needed: create an empty REGISTRY_CREDS authfile so write_pull_secret() does not fail on the missing file Fixes: openshift-metal3#1922 Assisted-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Roberto Alfieri <ralfieri@redhat.com> Co-authored-by: Cursor <cursoragent@cursor.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Hi @rebtoor. Thanks for your PR. I'm waiting for a openshift-metal3 member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
Hi @rebtoor — I've consolidated your
Added you as |
|
closed since the commit has been integrated into #1937 |
Summary
PR #1922 added an early
exit 0in02_configure_host.shforNODES_PLATFORM=baremetal, which skipssetup_local_registry.This breaks environments that combine
NODES_PLATFORM=baremetalwith
MIRROR_IMAGES=true(e.g. virtual-baremetal CI usingsushy-emulator on libvirt VMs), because
04_setup_ironic.shstillattempts to mirror release images into the local registry at port
5000 and gets "connection refused".
This affects downstream RHOSO CI jobs like
uni04delta-ipv6thatprovision OCP via Ironic on virtual baremetal nodes and require
image mirroring for IPv6 connectivity.
Changes
Add registry setup to the baremetal early-exit path in
02_configure_host.sh:use_registry "podman"): start theregistry and create
REGISTRY_CREDSviapodman login— mirrorsthe existing pattern in the libvirt path (lines 471–487)
use_registry ""): start it{}REGISTRY_CREDSauthfile so
write_pull_secret()does not fail on the missing fileRoot cause
The early-exit path introduced by #1922 assumed that baremetal
deployments never need a local registry. This is true for "real"
baremetal (standalone provisioning hosts pulling from external
registries), but not for virtual-baremetal setups that use
MIRROR_IMAGES=trueto mirror OCP release images locally.Related
write_pull_secret()crash; this PRfixes the registry not running)
(creates empty auth file but does not start the registry)
Test plan
NODES_PLATFORM=baremetal,MIRROR_IMAGES=true: registrystarts,
oc adm release mirrorsucceedsNODES_PLATFORM=baremetal,MIRROR_IMAGESunset: emptyauthfile created, no registry started,
write_pull_secret()worksNODES_PLATFORM=libvirt: no behavior change (early-exit blocknot reached)
Made with Cursor