ansible-role-certbot/tasks/setup-RedHat.yml
2020-06-13 14:20:26 +02:00

26 lines
642 B
YAML

---
# See: https://github.com/geerlingguy/ansible-role-certbot/issues/107
- block:
- name: Enable EPEL repo on CentOS 8+
yum:
name: https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
state: present
- name: Ensure dnf-plugins are installed on CentOS 8+.
yum:
name: dnf-plugins-core
state: present
- name: Enable DNF module for CentOS 8+.
shell: |
dnf config-manager --set-enabled PowerTools
args:
warn: false
register: dnf_module_enable
changed_when: false
when:
- ansible_os_family == 'RedHat'
- ansible_distribution_major_version | int >= 8