From 5a8ecab5ed2c2746c26dbe3263d5fec5aa2a30f6 Mon Sep 17 00:00:00 2001 From: Mathieu Tortuyaux Date: Wed, 4 Sep 2024 14:08:38 +0200 Subject: [PATCH] build_sysext: override FLATCAR_VERSION only for non-official builds Without this, official builds are failing: ``` This is a dev rebuild of an official release tag: No BUILD ID set in '/mnt/host/source/.repo/manifests/version.txt'. Will use base squasfs BUILD ID for version check. Repo root FLATCAR_VERSION is '4081.0.0', squashfs build ID is '2024-09-03-2245' Setting FLATCAR_VERSION to '4081.0.0+2024-09-03-2245' Base squashfs version: 4081.0.0 SDK board packages version: 4081.0.0+2024-09-03-2245 Version mismatch between board flatcar release and SDK container flatcar release. ``` The "base squashfs version" is the actual version for official release builds. Signed-off-by: Mathieu Tortuyaux --- build_sysext | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build_sysext b/build_sysext index 3d28e8627f..4fd7cd2bf5 100755 --- a/build_sysext +++ b/build_sysext @@ -188,7 +188,7 @@ REPO_BUILD_ID=$(source "${REPO_MANIFESTS_DIR}/version.txt"; echo "$FLATCAR_BUILD REPO_FLATCAR_VERSION=$(source "${REPO_MANIFESTS_DIR}/version.txt"; echo "$FLATCAR_VERSION") VERSION_BOARD=$(source "${BUILD_DIR}/fs-root/usr/lib/os-release" && echo "$VERSION") -if [[ -z $REPO_BUILD_ID ]] ; then +if [[ -z $REPO_BUILD_ID ]] && [[ ${COREOS_OFFICIAL:-0} -ne 1 ]]; then BASE_SQUASHFS_BUILD_ID=$(source "${BUILD_DIR}/fs-root/usr/lib/os-release" && echo -n "$BUILD_ID") info "This is a dev rebuild of an official release tag: No BUILD ID set in '${REPO_MANIFESTS_DIR}/version.txt'. Will use base squashfs BUILD ID for version check." info "Repo root FLATCAR_VERSION is '$REPO_FLATCAR_VERSION', squashfs build ID is '$BASE_SQUASHFS_BUILD_ID'"