From 9887783bc9508cf52de68705c5df7ba66fcba157 Mon Sep 17 00:00:00 2001 From: Anil Belur Date: Sat, 29 May 2021 13:47:14 +1000 Subject: [PATCH] Fix: Change powertools repoid to lowercase The repoids are renamed with CentOS 8.3 update breaks the packer builds. Now the correct repoid to use is 'powertools' instead of 'PowerTools' Error: No matching repo to modify: PowerTools. Ref: https: //wiki.centos.org/Manuals/ReleaseNotes/CentOS8.2011#Yum_repo_file_and_repoid_changes Issue: RELENG-3710 Change-Id: I43b943ddfc38facaa8c02f2d6ee98254e7ee3241 Signed-off-by: Anil Belur --- provision/install-base-pkgs-RedHat.yaml | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/provision/install-base-pkgs-RedHat.yaml b/provision/install-base-pkgs-RedHat.yaml index 201abfb..1e6ebdf 100644 --- a/provision/install-base-pkgs-RedHat.yaml +++ b/provision/install-base-pkgs-RedHat.yaml @@ -15,10 +15,18 @@ when: - ansible_facts['distribution_major_version'] is version('8', '<') -- name: Enable PowerTools - command: - cmd: dnf config-manager --set-enabled PowerTools - warn: no +- name: Enable Powertools + block: + - name: Enable powertools on version >= 8.3 + command: + cmd: dnf config-manager --set-enabled powertools + warn: no + when: ansible_facts['distribution_version'] is version('8.3', '>=') + - name: Enable Powertools on versions < 8.3 + command: + cmd: dnf config-manager --set-enabled PowerTools + warn: no + when: ansible_facts['distribution_version'] is version('8.3', '<') become: true when: ansible_facts['distribution_major_version'] is version('8', '>=') -- 2.16.6