-
Notifications
You must be signed in to change notification settings - Fork 202
Add option to mirror openshift images #850
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -185,3 +185,19 @@ function bmo_config_map { | |
|
|
||
| cp ocp/deploy/metal3-config.yaml assets/generated/99_metal3-config.yaml | ||
| } | ||
|
|
||
| function image_mirror_config { | ||
| if [ ! -z "${MIRROR_IMAGES}" ]; then | ||
| TAGGED=$(echo $OPENSHIFT_RELEASE_IMAGE | sed -e 's/release://') | ||
| RELEASE=$(echo $OPENSHIFT_RELEASE_IMAGE | grep -o 'registry.svc.ci.openshift.org[^":]\+') | ||
|
Comment on lines
+191
to
+192
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This doesn't always work, that's what I got while using nightly Success
Update image: 192.168.123.141:5000/localimages/local-release-image:4.3.0-0.nightly-2019-11-25-022933
Mirror prefix: 192.168.123.141:5000/localimages/local-release-image
To use the new mirrored repository to install, add the following section to the install-config.yaml:
imageContentSources:
- mirrors:
- 192.168.123.141:5000/localimages/local-release-image
source: quay.io/openshift-release-dev/ocp-v4.0-art-dev
- mirrors:
- 192.168.123.141:5000/localimages/local-release-image
source: registry.svc.ci.openshift.org/ocp/release
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe if the user wants to mirror images, we should ask them for the exact sources? What do you think? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I can confirm that was the behavior I got as well using 4.3 nightly's on an environment where I was doing disconnected. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't like how the data structure is laid out at all... What we have here is a hodge podge of array and string objects. It will be mind bending to code against this. How about ...
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is an API defined by OpenShift, it's not something we can revisit.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @mazzystr I'm not sure what you mean. We're simply using openshift-installer-provided values. We don't define any data structures. |
||
| cat << EOF | ||
| imageContentSources: | ||
| - mirrors: | ||
| - ${LOCAL_REGISTRY_ADDRESS}/localimages/local-release-image | ||
| source: ${RELEASE} | ||
| - mirrors: | ||
| - ${LOCAL_REGISTRY_ADDRESS}/localimages/local-release-image | ||
| source: ${TAGGED} | ||
| EOF | ||
| fi | ||
| } | ||
Uh oh!
There was an error while loading. Please reload this page.