Merge "Fix enabling epel repo for rpm distributions"
This commit is contained in:
commit
b7c5b437b5
@ -26,13 +26,24 @@
|
|||||||
command: dnf config-manager --set-enabled crb
|
command: dnf config-manager --set-enabled crb
|
||||||
when: ansible_distribution_version|int == 9
|
when: ansible_distribution_version|int == 9
|
||||||
|
|
||||||
- name: "Enable EPEL repository for EL7/8/9"
|
- name: "Enable EPEL repository for EL7/8"
|
||||||
ansible.builtin.dnf:
|
ansible.builtin.dnf:
|
||||||
name: epel-release
|
name: epel-release
|
||||||
|
state: latest
|
||||||
when:
|
when:
|
||||||
- enable_epel | bool
|
- enable_epel | bool
|
||||||
- ansible_distribution in ["AlmaLinux", "CentOS", "Rocky"]
|
- 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"
|
- name: "Enable EPEL repository for RedHat 9"
|
||||||
command: dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
|
command: dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
|
||||||
args:
|
args:
|
||||||
|
@ -66,6 +66,9 @@ case ${ID,,} in
|
|||||||
)
|
)
|
||||||
EXTRA_PKG_DEPS=()
|
EXTRA_PKG_DEPS=()
|
||||||
sudo -E ${PKG_MANAGER} updateinfo
|
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;;
|
*) echo "ERROR: Supported package manager not found. Supported: apt, dnf, yum, zypper"; exit 1;;
|
||||||
|
Loading…
Reference in New Issue
Block a user