From 872f10d7e6336dce188d2c743b7aee816fc69ee9 Mon Sep 17 00:00:00 2001 From: zimniy <zimniy@cyberbrain.pw> Date: Tue, 1 Jun 2021 16:37:42 +0300 Subject: [PATCH] "OracleLinux" --- tasks/centos/main.yml | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/tasks/centos/main.yml b/tasks/centos/main.yml index 1195a8b..992b2e8 100644 --- a/tasks/centos/main.yml +++ b/tasks/centos/main.yml @@ -1,15 +1,20 @@ --- - name: Enable EPEL repo with standard package - dnf: + ansible.builtin.dnf: name: epel-release state: present update_cache: yes when: apply_epel is defined and apply_epel and (ansible_distribution == 'CentOS' or ansible_distribution == 'Red Hat Enterprise Linux') -- name: Enable EPEL repo with external package - dnf: - name: "https://dl.fedoraproject.org/pub/epel/epel-release-latest-{{ ansible_distribution_major_version }}.noarch.rpm" - state: present - update_cache: yes +- block: + - name: Enable EPEL GPG key for externel repo + ansible.builtin.rpm_key: + state: present + key: "https://dl.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-{{ ansible_distribution_major_version }}" + - name: Enable EPEL repo with external package + ansible.builtin.dnf: + name: "https://dl.fedoraproject.org/pub/epel/epel-release-latest-{{ ansible_distribution_major_version }}.noarch.rpm" + state: present + update_cache: yes when: apply_epel is defined and apply_epel and ansible_distribution == 'OracleLinux' -- GitLab