tests: Fix failing cross distro test due to osbuild/images pseudo-version

The cross distro test started failing on RHEL 10.1, because the osbuild/images version was a Go pseudo-version that the sed command parsing the version did not recognize.
This commit is contained in:
Tom Koscielniak 2025-05-28 15:30:33 +02:00 committed by Tomáš Hozza
parent b3fab64dcc
commit 488a53e106

View file

@ -102,7 +102,7 @@ fi
# determine the 'osbuild/images' repository version used by the osbuild-composer
sudo dnf install -y golang
COMPOSER_DEPS=$(go version -m /usr/libexec/osbuild-composer/osbuild-composer)
IMAGES_VERSION=$(echo "$COMPOSER_DEPS" | sed -n 's|^\t\+dep\t\+github\.com/osbuild/images\t\+\(v[0-9.]\+\)\t\+$|\1|p')
IMAGES_VERSION=$(echo "$COMPOSER_DEPS" | sed -n 's|^\t\+dep\t\+github\.com/osbuild/images\t\+\(v[0-9.a-zA-Z-]\+\)\t\+$|\1|p')
if [ -z "$IMAGES_VERSION" ]; then
echo "ERROR: Unable to determine osbuild/images version from osbuild-composer binary. Composer deps:"
echo "$COMPOSER_DEPS"