Packit: Bump podman-next repo priority for cockpit tests

TMT_TREE envvar is ok to use in this case as it will only be used on
upstream packit tests.

Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
This commit is contained in:
Lokesh Mandvekar
2025-11-12 09:19:48 -05:00
parent c134825013
commit 07e4b253c6
3 changed files with 21 additions and 6 deletions

View File

@@ -0,0 +1,14 @@
#!/usr/bin/env bash
set -exo pipefail
COPR_REPO_FILE="/etc/yum.repos.d/_copr:copr.fedorainfracloud.org:rhcontainerbot:podman-next.repo"
if compgen -G "$COPR_REPO_FILE" > /dev/null; then
# We want the priority bump appended to the file, we're not looking
# to use a variable.
# shellcheck disable=SC2016
sed -i -n '/^priority=/!p;$apriority=1' "$COPR_REPO_FILE"
fi
# We want all dependencies from podman-next except podman as podman will be fetched
# from the packit copr.
dnf -y upgrade --allowerasing --exclude=podman*

View File

@@ -15,6 +15,12 @@ discover:
execute:
how: tmt
prepare:
when: initiator == packit
how: shell
script: bash $TMT_TREE/contrib/packit-tmt/podman-next-setup.sh
order: 20
# not relevant for testing podman
environment:
TEST_AUDIT_NO_SELINUX: 1

View File

@@ -16,12 +16,7 @@ prepare:
order: 10
- when: initiator == packit
how: shell
script: |
COPR_REPO_FILE="/etc/yum.repos.d/*podman-next*.repo"
if compgen -G $COPR_REPO_FILE > /dev/null; then
sed -i -n '/^priority=/!p;$apriority=1' $COPR_REPO_FILE
fi
dnf -y upgrade --allowerasing --exclude=podman*
script: bash $TMT_TREE/contrib/packit-tmt/podman-next-setup.sh
order: 20
adjust+: