]> git.apps.os.sepia.ceph.com Git - ceph-cm-ansible.git/commitdiff
testnode: Update SELinux policy when configuring NRPE 231/head
authorDavid Galloway <dgallowa@redhat.com>
Fri, 22 Apr 2016 22:50:10 +0000 (18:50 -0400)
committerDavid Galloway <dgallowa@redhat.com>
Fri, 22 Apr 2016 22:59:37 +0000 (18:59 -0400)
The 'nagios_run_sudo' boolean was added after RHEL7.1 GA.

https://rhn.redhat.com/errata/RHBA-2015-1140.html

Attempting to set the boolean when it's not present causes ansible
to fail.  NRPE will cause SELinux failures in test jobs unless set
so the only other option would be to disable NRPE on
RHEL/CentOS <= 7.1

This change ensures the testnode has the latest version of SELinux
policy installed, and thus, ensuring the boolean exists.

Signed-off-by: David Galloway <dgallowa@redhat.com>
roles/testnode/tasks/nrpe-selinux.yml

index 2fd781ab3293450258fe86b4f5d04bb31292a136..877aa2e29e34a1dc5ed33e742e720f5584390823 100644 (file)
@@ -9,6 +9,11 @@
     pkg: policycoreutils-python
     state: installed
 
+- name: nrpe - Ensure SELinux policy is up to date
+  yum:
+    pkg: selinux-policy-targeted
+    state: latest
+
 - name: nrpe - Set SELinux boolean nagios_run_sudo true
   seboolean:
     name: nagios_run_sudo