From: David Galloway Date: Mon, 11 Jul 2016 22:55:15 +0000 (-0400) Subject: common: Move nrpe package install to common role X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=53d192ebab835a29c538c6cb3beb527c0555c307;p=ceph-cm-ansible.git common: Move nrpe package install to common role Signed-off-by: David Galloway --- diff --git a/roles/common/tasks/nagios.yml b/roles/common/tasks/nagios.yml index 259a2298..7d83766f 100644 --- a/roles/common/tasks/nagios.yml +++ b/roles/common/tasks/nagios.yml @@ -1,4 +1,31 @@ --- +- name: Include apt_system vars + include_vars: apt_systems.yml + when: ansible_pkg_mgr == "apt" + +- name: Include yum_systems vars + include_vars: yum_systems.yml + when: ansible_pkg_mgr == "yum" + +- name: Install nrpe package and dependencies (RHEL/CentOS) + yum: + name: "{{ item }}" + state: latest + enablerepo: epel + with_items: + - nrpe + - smartmontools + when: ansible_pkg_mgr == "yum" + +- name: Install nrpe package and dependencies (Ubuntu) + apt: + name: "{{ item }}" + state: latest + with_items: + - nagios-nrpe-server + - smartmontools + when: ansible_pkg_mgr == "apt" + - name: Upload nagios sudoers.d for raid utilities. template: src: nagios/90-nagios