Update upstream tests to disable fedora repos

c10s upstream testing is running with fedora repos as a workaround to
not having EPEL10 available yet.  So, to avoid an issue of installing
the wrong version, we have to disable those repos and uninstall then
re-install jq from the correct repos. and download source rpm with
those repos disabled.
This commit is contained in:
Scott Poore 2024-10-16 13:13:51 -05:00 committed by Tomas Halman
parent 0d0888a448
commit f7e27fc872

View File

@ -5,10 +5,14 @@ die () {
exit 1 exit 1
} }
dnf list jq
dnf remove -y jq
dnf --disablerepo=fedora* --disablerepo=updates* install -y jq jq-devel
# If source not found, download it with dnf # If source not found, download it with dnf
if [ ! -d ./source ]; then if [ ! -d ./source ]; then
# Extract source from srpm # Extract source from srpm
dnf download --source jq && \ dnf --disablerepo=fedora* --disablerepo=updates* download --source jq && \
rpm2cpio jq*.rpm|cpio -id && \ rpm2cpio jq*.rpm|cpio -id && \
mkdir source && \ mkdir source && \
tar -zxf jq-*.tar.gz -C source --strip-components=1 tar -zxf jq-*.tar.gz -C source --strip-components=1