diff --git a/diskimage_builder/elements/centos/pre-install.d/01-set-centos-mirror b/diskimage_builder/elements/centos/pre-install.d/01-set-centos-mirror index eb6a83df..37c45dbc 100755 --- a/diskimage_builder/elements/centos/pre-install.d/01-set-centos-mirror +++ b/diskimage_builder/elements/centos/pre-install.d/01-set-centos-mirror @@ -14,12 +14,12 @@ DIB_DISTRIBUTION_MIRROR=${DIB_DISTRIBUTION_MIRROR:-} # The others aren't enabled and do not exist on all mirrors if [[ ${DIB_RELEASE} == '7' ]]; then sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\(centos\|altarch\)/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-Base.repo -elif [[ ${DIB_RELEASE} > '7' ]]; then - sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-Base.repo - sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-AppStream.repo - sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-centosplus.repo - sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-Extras.repo - sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-PowerTools.repo +else + sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-Linux-BaseOS.repo + sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-Linux-AppStream.repo + sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-Linux-Plus.repo + sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-Linux-Extras.repo + sed -e "s,^#baseurl=http[s]*://mirror.centos.org/\$contentdir/,baseurl=$DIB_DISTRIBUTION_MIRROR/,;/^mirrorlist=/d" -i /etc/yum.repos.d/CentOS-Linux-PowerTools.repo fi # CentOS Stream releases (e.g. 8-stream, 9-stream) diff --git a/diskimage_builder/elements/yum-minimal/root.d/08-yum-chroot b/diskimage_builder/elements/yum-minimal/root.d/08-yum-chroot index 56ae87ca..cbcc13d9 100755 --- a/diskimage_builder/elements/yum-minimal/root.d/08-yum-chroot +++ b/diskimage_builder/elements/yum-minimal/root.d/08-yum-chroot @@ -91,7 +91,8 @@ function _install_repos { # CentOS 8.1 split repositories and GPG keys out into subpackages if [[ ${DISTRO_NAME} = centos && ${DIB_RELEASE} > "7" ]]; then - packages+="centos-repos centos-gpg-keys " + packages+="centos-linux-release centos-linux-repos centos-gpg-keys " + if [[ "$DIB_RELEASE" =~ (stream) ]]; then packages+="centos-stream-release centos-stream-repos " fi diff --git a/lower-constraints.txt b/lower-constraints.txt index 5f31b45d..86f834a7 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -7,7 +7,7 @@ docutils==0.11 dulwich==0.15.0 extras==1.0.0 fixtures==3.0.0 -flake8==2.5.4 +flake8==3.8.4 hacking==0.10.0 imagesize==0.7.1 iso8601==0.1.11 @@ -25,7 +25,7 @@ os-client-config==1.28.0 oslotest==3.2.0 pbr==2.0.0 pep8==1.5.7 -pyflakes==0.8.1 +pyflakes==2.2.0 Pygments==2.2.0 pylint==1.7.1 python-mimeparse==1.6.0