From e033c0521b72e109231ede2bf5fed6586ad9103a Mon Sep 17 00:00:00 2001 From: rsvr76 Date: Wed, 19 Aug 2026 20:27:34 +0530 Subject: [PATCH] contrib/packit-tmt: handle missing testing-farm repo Check for testing-farm-tag-repository before passing --disable-repo to dnf. This prevents the dependency upgrade from failing when Testing Farm did not create the repository. Fixes: #28452 Signed-off-by: rsvr76 --- contrib/packit-tmt/update-deps.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/contrib/packit-tmt/update-deps.sh b/contrib/packit-tmt/update-deps.sh index dc2d14dc95..50fa90b832 100644 --- a/contrib/packit-tmt/update-deps.sh +++ b/contrib/packit-tmt/update-deps.sh @@ -2,6 +2,11 @@ set -exo pipefail +DISABLE_REPO=() +if grep -s -r -q -F '[testing-farm-tag-repository]' /etc/yum.repos.d 2>/dev/null; then + DISABLE_REPO=(--disable-repo=testing-farm-tag-repository) +fi + # This should work even when podman-next isn't installed. It'll fetch the # highest versions available across all repos. -dnf -y upgrade --allowerasing --disable-repo=testing-farm-tag-repository --exclude=podman* +dnf -y upgrade --allowerasing "${DISABLE_REPO[@]}" --exclude=podman*