Skip to content

Commit 93c7ae1

Browse files
committed
AGENT-1193: Add IDMS entry for local registry in mirror preparation
When preparing the registry directory for appliance builds, append an IDMS entry for the local dev-scripts registry to the existing idms-oc-mirror.yaml file. This mapping is needed when dev-scripts builds custom images and pushes them to a custom release image with URIs that reference the dev-scripts registry (e.g., virthost.ostest.test.metalkube.org:5000). The IDMS entry allows the appliance to create the proper registry mappings for these custom images. This change is part of the mirror-path support for OVE ISO builds in disconnected environments. Assisted-by: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent 084202f commit 93c7ae1

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

agent/04_agent_prepare_release.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,24 @@ function prepare_registry_dir_for_appliance() {
5757
fi
5858
done
5959

60+
# Append IDMS entry for local dev-scripts registry to existing idms-oc-mirror.yaml
61+
# This ensures the local registry can be accessed from the installed cluster
62+
echo "Appending IDMS entry for local registry"
63+
64+
# Local dev-scripts registry
65+
local local_registry="${LOCAL_REGISTRY_DNS_NAME}:${LOCAL_REGISTRY_PORT}"
66+
67+
echo "Creating IDMS mapping: ${local_registry} -> ${local_registry}"
68+
69+
# Append mirror entry to existing IDMS file
70+
cat >> ${REGISTRY_DIR}/working-dir/cluster-resources/idms-oc-mirror.yaml << EOF
71+
- mirrors:
72+
- ${local_registry}
73+
source: ${local_registry}
74+
EOF
75+
76+
echo "Custom registry IDMS entry appended to ${REGISTRY_DIR}/working-dir/cluster-resources/idms-oc-mirror.yaml"
77+
6078
echo "Registry directory prepared for appliance"
6179
}
6280

0 commit comments

Comments
 (0)