From 7758a908cbd837fbf0369b4902c8737976aa69bb Mon Sep 17 00:00:00 2001 From: Honza Horak Date: Tue, 3 Sep 2024 16:20:53 +0200 Subject: [PATCH] Be more cautious about what images to pull The set is different on different distro versions, so let's not let docker pull fail, instead be more cautious about what versions we actually expect to exist. --- test/run_test | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/test/run_test b/test/run_test index e0557a64..2c0c52f9 100755 --- a/test/run_test +++ b/test/run_test @@ -686,14 +686,33 @@ run_upgrade_test () { local ret=0 - local upgrade_path="none 12 13 15 16 none" prev= act= + local upgrade_path= prev= act= + case $OS in + rhel8) + upgrade_path="none 12 13 15 16 none" + ;; + rhel9|c9s) + upgrade_path="none 13 15 16 none" + ;; + rhel10|c10s) + upgrade_path="none 13 15 16 none" + ;; + fedora) + upgrade_path="none 12 13 14 15 16 none" + ;; + *) + echo "unsupported OS variable" >&2 + return 1 + ;; + esac + for act in $upgrade_path; do if test "$act" = $VERSION; then break fi prev=$act done - test "$prev" != none + test "$prev" != none || return 0 # Check if the previous image is available in the registry docker pull "$(get_image_id "$prev:remote")" || return 0