gitlab-ci: fix CentOS Linux 9 containers during ".gitlab-ci/fedora-install.sh"

https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/merge_requests/1511
This commit is contained in:
Fernando Fernandez Mancera 2023-01-23 22:09:14 +01:00 committed by Thomas Haller
parent 128c000f0c
commit 74f66ee276
No known key found for this signature in database
GPG key ID: 29C2366E4DFC5728
2 changed files with 11 additions and 9 deletions

View file

@ -53,10 +53,10 @@ variables:
#
# This is done by running `ci-fairy generate-template` and possibly bumping
# ".default_tag".
FEDORA_TAG: '2023-01-18.0-1423f8164e71'
FEDORA_TAG: '2023-01-18.0-296fbfd97862'
UBUNTU_TAG: '2023-01-18.0-08fb4e6eb861'
DEBIAN_TAG: '2023-01-18.0-08fb4e6eb861'
CENTOS_TAG: '2023-01-18.0-1423f8164e71'
CENTOS_TAG: '2023-01-18.0-296fbfd97862'
ALPINE_TAG: '2023-01-18.0-14c807942fa4'
FEDORA_EXEC: 'bash .gitlab-ci/fedora-install.sh'

View file

@ -23,19 +23,21 @@ fi
localedef -c -i pl_PL -f UTF-8 pl_PL.UTF-8
locale -a
yum install -y python36-dbus python36-gobject-base
else
if [ $IS_CENTOS_8 = 1 ]; then
# CentOS Linux 8 is now EOF and plain `dnf upgrade` does not work. We need
# to patch the mirror list.
sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-*
sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*
fi
elif [ $IS_CENTOS_8 = 1 ]; then
# CentOS Linux 8 is now EOF and plain `dnf upgrade` does not work. We need
# to patch the mirror list.
sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-*
sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*
dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
dnf install -y 'dnf-command(config-manager)'
dnf config-manager --set-enabled powertools || \
dnf config-manager --set-enabled PowerTools
curl https://copr.fedorainfracloud.org/coprs/nmstate/nm-build-deps/repo/epel-8/nmstate-nm-build-deps-epel-8.repo > /etc/yum.repos.d/nmstate-nm-build-deps-epel-8.repo
else
dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
dnf install -y 'dnf-command(config-manager)'
curl https://copr.fedorainfracloud.org/coprs/nmstate/nm-build-deps/repo/epel-9/nmstate-nm-build-deps-epel-9.repo > /etc/yum.repos.d/nmstate-nm-build-deps-epel-9.repo
fi
fi