ansible-roles/drbd-utils/tasks/nagios.yml

20 lines
515 B
YAML
Raw Normal View History

2016-12-16 12:27:38 +01:00
---
- name: Check if Nagios is installed
stat:
path: /usr/local/lib/nagios/plugins/
register: nagios_plugins_dir
- name: Mount /usr in rw
command: mount -o remount,rw /usr warn=no
changed_when: False
when: nagios_plugins_dir.stat.exist
# https://exchange.nagios.org/components/com_mtree/attachment.php?link_id=3367&cf_id=30
- name: Install Nagios plugin
copy:
src: "nagios/check_drbd"
dest: "/usr/local/lib/nagios/plugins/check_drbd"
mode: "755"
when: nagios_plugins_dir.stat.exist