From: David Galloway Date: Thu, 24 Mar 2022 19:06:57 +0000 (-0400) Subject: common: Split out ethtool install so we can enable epel on CentOS X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=ad1c5dda7fee9037e98cb89df79f0b596a3ea52e;p=ceph-cm-ansible.git common: Split out ethtool install so we can enable epel on CentOS Signed-off-by: David Galloway --- diff --git a/roles/common/tasks/secondary_nic.yml b/roles/common/tasks/secondary_nic.yml index 8eb2ef69..557201b5 100644 --- a/roles/common/tasks/secondary_nic.yml +++ b/roles/common/tasks/secondary_nic.yml @@ -1,8 +1,18 @@ --- -- name: Make sure ethtool is installed - package: +- name: Make sure ethtool is installed (Ubuntu) + apt: name: ethtool - state: latest + state: present + when: ansible_os_family == 'Debian' + +- name: Make sure ethtool is installed (CentOS/RHEL) + yum: + name: ethtool + state: present + enablerepo: epel + when: + - ansible_os_family == 'RedHat' + - enable_epel|bool == true - name: grep ethtool for secondary NIC MAC address shell: "ethtool -P {{ item }} | awk '{ print $3 }' | grep -q -i '{{ secondary_nic_mac }}'"