Skip to content

Commit 510b694

Browse files
committed
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.
1 parent 7e7bc2b commit 510b694

File tree

1 file changed

+21
-2
lines changed

1 file changed

+21
-2
lines changed

test/run_test

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -686,14 +686,33 @@ run_upgrade_test ()
686686
{
687687
local ret=0
688688

689-
local upgrade_path="none 12 13 15 16 none" prev= act=
689+
local upgrade_path= prev= act=
690+
case $OS in
691+
rhel8)
692+
upgrade_path="none 12 13 15 16 none"
693+
;;
694+
rhel9|c9s)
695+
upgrade_path="none 13 15 16 none"
696+
;;
697+
rhel10|c10s)
698+
upgrade_path="none 13 15 16 none"
699+
;;
700+
fedora)
701+
upgrade_path="none 12 13 14 15 16 none"
702+
;;
703+
*)
704+
echo "unsupported OS variable" >&2
705+
return 1
706+
;;
707+
esac
708+
690709
for act in $upgrade_path; do
691710
if test "$act" = $VERSION; then
692711
break
693712
fi
694713
prev=$act
695714
done
696-
test "$prev" != none
715+
test "$prev" != none || return 0
697716
# Check if the previous image is available in the registry
698717
docker pull "$(get_image_id "$prev:remote")" || return 0
699718

0 commit comments

Comments
 (0)