commit d69b959a5e3034ee708771f18c21428bae0db25b Author: Stig Telfer Date: Wed Sep 30 17:49:27 2020 +0100 When EPEL install flag is not set The flag dnf_install_epel was being used to predicate installation of the EPEL RPM repo package, but not preventing the installation of configuration for access to EPEL. This small patch completes the job. Updates the overcloud host configure CI job to install EPEL mirrors, since it was previously relying on this buggy behaviour. Change-Id: Ib417837d0772338b16ea9f7f2540549f277d5de8 (cherry picked from commit e5a2818896a47c902487ea9aa97b5a4a03f2b9d6) diff --git a/ansible/roles/dnf/tasks/local-mirror.yml b/ansible/roles/dnf/tasks/local-mirror.yml index 405b5c8..afc6363 100644 --- a/ansible/roles/dnf/tasks/local-mirror.yml +++ b/ansible/roles/dnf/tasks/local-mirror.yml @@ -38,9 +38,11 @@ loop: - epel.repo - epel-modular.repo + when: dnf_install_epel | bool - name: Update cache dnf: name: [] update_cache: yes become: True + when: dnf_install_epel | bool diff --git a/ansible/roles/yum/tasks/local-mirror.yml b/ansible/roles/yum/tasks/local-mirror.yml index e730b00..93d775c 100644 --- a/ansible/roles/yum/tasks/local-mirror.yml +++ b/ansible/roles/yum/tasks/local-mirror.yml @@ -26,6 +26,7 @@ name: epel-release state: present become: True + when: yum_install_epel | bool - name: Template | Copy EPEL repo templates (CentOS) template: @@ -35,9 +36,11 @@ group: root mode: 0664 become: True + when: yum_install_epel | bool - name: Yum | Update cache (CentOS) yum: name: '*' update_cache: yes become: True + when: yum_install_epel | bool diff --git a/playbooks/kayobe-overcloud-host-configure-base/overrides.yml.j2 b/playbooks/kayobe-overcloud-host-configure-base/overrides.yml.j2 index 51d1119..847d375 100644 --- a/playbooks/kayobe-overcloud-host-configure-base/overrides.yml.j2 +++ b/playbooks/kayobe-overcloud-host-configure-base/overrides.yml.j2 @@ -120,8 +120,6 @@ dnf_custom_repos: baseurl: http://packages.treasuredata.com/3/redhat/$releasever/$basearch gpgkey: https://packages.treasuredata.com/GPG-KEY-td-agent gpgcheck: yes -# Don't install EPEL repositories. -dnf_install_epel: false # Enable DNF Automatic. dnf_automatic_enabled: true {% endif %}