From 0248c4c8e6a10847edd7a2b2386175cb3338c975 Mon Sep 17 00:00:00 2001 From: Dan Mick Date: Thu, 23 Oct 2025 15:27:51 -0700 Subject: [PATCH] scripts/build_container: calculate and use FROM_IMAGE Instruct ceph.git's container/build.sh which image to use as the container base, specified by env vars DISTRO and RELEASE Signed-off-by: Dan Mick --- scripts/build_container | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/scripts/build_container b/scripts/build_container index aef0d97d..96373eab 100755 --- a/scripts/build_container +++ b/scripts/build_container @@ -37,5 +37,11 @@ if [[ $CI_CONTAINER == "true" && $DISTRO == "centos" && "$RELEASE" =~ 8|9 ]] ; t cd ${WORKSPACE} # older jobs used a versioned directory; ceph-dev-pipeline uses an unversioned dir. [[ -d ./dist/ceph/container ]] && cd ./dist/ceph/container || cd dist/ceph-${cephver}/container - CEPH_SHA1=${SHA1} ./build.sh + from_image_spec="${DISTRO}:${RELEASE}" + case "${from_image_spec}" in + "centos:stream9") FROM_IMAGE=quay.io/centos/centos:stream9 ;; + "rocky:10") FROM_IMAGE=docker.io/rockylinux/rockylinux:10 ;; + *) echo "Don't know requested FROM image ${from_image_spec}; exit 1 ;; + esac + FROM_IMAGE=${FROM_IMAGE} CEPH_SHA1=${SHA1} ./build.sh fi -- 2.39.5