From ae2be0b464392256df7009f7030281963c06aa81 Mon Sep 17 00:00:00 2001 From: Carlos Goncalves Date: Wed, 15 Jan 2020 19:37:03 +0100 Subject: [PATCH] Fix Yum repositories and GPG keys for CentOS 8.1 CentOS 8.1 split repositories and GPG keys out into subpackages. This broke DIB support for CentOS 8. https://git.centos.org/rpms/centos-release/c/7e41cef418ab8781dab118e81f811221dd83c226?branch=c8 https://git.centos.org/rpms/centos-release/c/26a0d73cedb9a2bfbcc38459344111fea231c577?branch=c8 Change-Id: If3de6efa6074e059dc9fdd47c7bdc19d26d4d7f2 --- diskimage_builder/elements/yum-minimal/root.d/08-yum-chroot | 5 +++++ 1 file changed, 5 insertions(+) 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 d98a96bc8..687760c85 100755 --- a/diskimage_builder/elements/yum-minimal/root.d/08-yum-chroot +++ b/diskimage_builder/elements/yum-minimal/root.d/08-yum-chroot @@ -89,6 +89,11 @@ function _install_repos { packages+="fedora-gpg-keys " fi + # CentOS 8.1 split repositories and GPG keys out into subpackages + if [[ ${DISTRO_NAME} = centos && ${DIB_RELEASE} -ge 8 ]]; then + packages+="centos-repos centos-gpg-keys " + fi + # By default, parent elements (fedora-minimal, centos-minimal) # have a yum.repos.d directory in the element with a default repo; # this is copied to TMP_HOOK_PATH by the usual hook-copying