Skip to content

Commit 87fd8ea

Browse files
committed
Revert "build-patched-kao-kcmo-images.sh: get image name from brew container image metadata"
This reverts commit a2b6ece. Revert "kao-kcmo-images.sh: Don't hardcode the image name" This reverts commit d4ca7af. Revert "kao-kcmo-images.sh: Add reference for `image_from_brew` variable" This reverts commit 8c64f2d. We need to revert since the metadata file is not available for quite some time even after the brew build successful and CI is failing because of that with following error. ``` ++ curl -L https://download.eng.bos.redhat.com/brewroot/packages/crc-cluster-kube-apiserver-operator-container/v4.15.0/202406052127.p0.geae6926.assembly.stream.el9/metadata.json ++ jq -r '.build.extra.image.index.pull[0]' % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 100 328 100 328 0 0 2000 0 --:--:-- --:--:-- --:--:-- 2012 parse error: Invalid numeric literal at line 1, column 10 ```
1 parent 85fd30d commit 87fd8ea

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

build-patched-kao-kcmo-images.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,10 @@ function patch_and_push_image() {
9999
rhpkg container-build --target crc-1-rhel-9-candidate
100100
popd
101101
fi
102-
# Metadata output from pull list offers 2 variants - SHA digest variant and tag variant.
103-
# They are essentially the same, so we can choose either ([0] or [1]).
104-
image_from_brew=$(curl -L https://download.eng.bos.redhat.com/brewroot/packages/crc-${image_name}-container/${version}/${release}/metadata.json | jq -r '.build.extra.image.index.pull[0]')
105-
skopeo copy --dest-authfile ${OPENSHIFT_PULL_SECRET_PATH} --all --src-cert-dir=pki/ docker://${image_from_brew} docker://quay.io/crcont/openshift-crc-${image_name}:${openshift_version}
102+
# Operator images created using rhel-9 tags have `rhel9-operator` as part of image name so replacing `operator` with it.
103+
# https://www.gnu.org/software/bash/manual/bash.html#Shell-Parameter-Expansion
104+
rhel9_image_name="${image_name/operator/rhel9-operator}"
105+
skopeo copy --dest-authfile ${OPENSHIFT_PULL_SECRET_PATH} --all --src-cert-dir=pki/ docker://registry-proxy.engineering.redhat.com/rh-osbs/openshift-crc-${rhel9_image_name}:${version}-${release} docker://quay.io/crcont/openshift-crc-${image_name}:${openshift_version}
106106
}
107107

108108
function create_patched_release_image_for_arch() {

0 commit comments

Comments
 (0)