diff --git a/playbooks/roles/bifrost-ironic-install/tasks/install.yml b/playbooks/roles/bifrost-ironic-install/tasks/install.yml index b9f2a5f24..cbceb2de3 100644 --- a/playbooks/roles/bifrost-ironic-install/tasks/install.yml +++ b/playbooks/roles/bifrost-ironic-install/tasks/install.yml @@ -26,12 +26,23 @@ command: dnf config-manager --set-enabled crb when: ansible_distribution_version|int == 9 - - name: "Enable EPEL repository for EL7/8/9" + - name: "Enable EPEL repository for EL7/8" ansible.builtin.dnf: name: epel-release - when: - - enable_epel | bool - - ansible_distribution in ["AlmaLinux", "CentOS", "Rocky"] + state: latest + when: + - enable_epel | bool + - ansible_distribution in ["AlmaLinux", "CentOS", "Rocky"] + + - name: "Enable EPEL repositories for EL9" + ansible.builtin.dnf: + name: + - epel-next-release + state: latest + when: + - enable_epel | bool + - ansible_distribution == 'CentOS' + - ansible_distribution_version|int == 9 - name: "Enable EPEL repository for RedHat 9" command: dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm diff --git a/scripts/install-deps.sh b/scripts/install-deps.sh index bdeaec29f..a8155d51a 100755 --- a/scripts/install-deps.sh +++ b/scripts/install-deps.sh @@ -66,6 +66,9 @@ case ${ID,,} in ) EXTRA_PKG_DEPS=() sudo -E ${PKG_MANAGER} updateinfo + # NOTE(rpittau): epel repos are installed but the content is purged + # in the CI images, we remove them and reinstall later + sudo -E ${PKG_MANAGER} remove -y epel-release epel-next-release ;; *) echo "ERROR: Supported package manager not found. Supported: apt, dnf, yum, zypper"; exit 1;;