From dab2daa37ac38ff1d7e88df553d5d35ddc0da899 Mon Sep 17 00:00:00 2001 From: Micah Abbott Date: Mon, 23 May 2022 12:53:41 -0400 Subject: [PATCH] ci: fix prow-build.sh to fetch same repos The introduction of new Prow periodic jobs (openshift/release#27779) means we have to keep the `prow-build.sh` and `prow-build-test-qemu.sh` scripts in sync, with regards to fetching the repo configs. This brings `prow-build.sh` in sync with the changes from #796. Closes #801 --- ci/prow-build-test-qemu.sh | 4 ++++ ci/prow-build.sh | 15 ++++++++++----- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/ci/prow-build-test-qemu.sh b/ci/prow-build-test-qemu.sh index 35c0ee15d..883dd2edd 100755 --- a/ci/prow-build-test-qemu.sh +++ b/ci/prow-build-test-qemu.sh @@ -25,6 +25,10 @@ if test '!' -w src/config; then mv src/config.writable src/config fi +# +# NOTE: If you are adjusting how the repos are fetched in this script, you +# must also make the same change in the `prow-build.sh` script +# # Grab the raw value of `mutate-os-release` and use sed to convert the value # to X-Y format ocpver=$(rpm-ostree compose tree --print-only src/config/manifest.yaml | jq -r '.["mutate-os-release"]') diff --git a/ci/prow-build.sh b/ci/prow-build.sh index 0f28dd6c4..09b40a525 100755 --- a/ci/prow-build.sh +++ b/ci/prow-build.sh @@ -34,16 +34,21 @@ if test '!' -w src/config; then mv src/config.writable src/config fi +# +# NOTE: If you are adjusting how the repos are fetched in this script, you +# must also make the same change in the `prow-build-test-qemu.sh` script +# # Grab the raw value of `mutate-os-release` and use sed to convert the value # to X-Y format ocpver=$(rpm-ostree compose tree --print-only src/config/manifest.yaml | jq -r '.["mutate-os-release"]') ocpver_mut=$(rpm-ostree compose tree --print-only src/config/manifest.yaml | jq -r '.["mutate-os-release"]' | sed 's|\.|-|') prev_build_url=${REDIRECTOR_URL}/rhcos-${ocpver}/ -# temporarily also fetch 8.5 repo for sssd -# https://bugzilla.redhat.com/show_bug.cgi?id=2072050 -curl -L http://base-"${ocpver_mut}"-rhel86.ocp.svc.cluster.local > src/config/ocp.repo -curl -L http://base-"${ocpver_mut}"-rhel85.ocp.svc.cluster.local > src/config/ocp85.repo -sed -i -e 's,\[rhel-8-,\[rhel-85-,' src/config/ocp85.repo +# we want to use RHEL 8.5 for testing until we can start using 8.6 +# see https://github.com/openshift/release/pull/26193 +curl -L http://base-"${ocpver_mut}"-rhel85.ocp.svc.cluster.local > src/config/ocp.repo +# fetch the 8.6 appstream repo to enable building of extensions +# see: https://github.com/openshift/os/issues/795 +curl -Ls http://base-"${ocpver_mut}"-rhel86.ocp.svc.cluster.local | grep -A 3 rhel-8-appstream | sed '1,3 s/rhel-8-appstream/rhel-86-appstream/g' >> src/config/ocp.repo cosa buildfetch --url=${prev_build_url} cosa fetch cosa build