forked from ISTI-ansible-roles/ansible-roles
Merge branch 'master' of adellam/ansible-roles into master
This commit is contained in:
commit
8ab0ae36e6
|
@ -53,6 +53,8 @@ nagios_psql_db_size_c: 170000000
|
||||||
nagios_psql_wal_files_w: 20
|
nagios_psql_wal_files_w: 20
|
||||||
nagios_psql_wal_files_c: 40
|
nagios_psql_wal_files_c: 40
|
||||||
|
|
||||||
|
#nagios_additional_checkdisk_options: '-i "/path/.*/to/dir" -A /foo'
|
||||||
|
|
||||||
nrpe_command_timeout: 420
|
nrpe_command_timeout: 420
|
||||||
nrpe_include_dir: /etc/nagios/nrpe.d/
|
nrpe_include_dir: /etc/nagios/nrpe.d/
|
||||||
|
|
||||||
|
|
|
@ -33,30 +33,23 @@
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Install the Dell OMSA packages dependencies
|
- name: Install the Dell OMSA packages dependencies
|
||||||
apt: pkg={{ item }} state=present force=yes update_cache=yes cache_valid_time=1800
|
apt: pkg={{ nagios_dell_omsa_deps }} state=present force=yes update_cache=yes cache_valid_time=1800
|
||||||
with_items: '{{ nagios_dell_omsa_deps }}'
|
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Install other Dell OMSA packages dependencies
|
- name: Install other Dell OMSA packages dependencies
|
||||||
apt: pkg={{ item }} state=present update_cache=yes cache_valid_time=1800
|
apt: pkg=python-requests state=present update_cache=yes cache_valid_time=1800
|
||||||
with_items:
|
|
||||||
- python-requests
|
|
||||||
register: requests_pkg
|
register: requests_pkg
|
||||||
ignore_errors: True
|
ignore_errors: True
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Install the python-pip package if requests is not available as a package
|
- name: Install the python-pip package if requests is not available as a package
|
||||||
apt: pkg={{ item }} state=present update_cache=yes cache_valid_time=1800
|
apt: pkg=python-pip state=present update_cache=yes cache_valid_time=1800
|
||||||
with_items:
|
when: requests_pkg is failed
|
||||||
- python-pip
|
|
||||||
when: requests_pkg|failed
|
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Install the python-requests package via pip if it s not available as package
|
- name: Install the python-requests package via pip if it s not available as package
|
||||||
pip: name={{ item }} state=latest use_mirrors=no
|
pip: name=requests state=latest use_mirrors=no
|
||||||
with_items:
|
when: requests_pkg is failed
|
||||||
- requests
|
|
||||||
when: requests_pkg|failed
|
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Get the old libssl0.9.8_9.9.8 needed by del Dell OMSA utilities on debian 7
|
- name: Get the old libssl0.9.8_9.9.8 needed by del Dell OMSA utilities on debian 7
|
||||||
|
@ -71,20 +64,16 @@
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Install the main Dell OMSA package
|
- name: Install the main Dell OMSA package
|
||||||
apt: pkg={{ item }} state={{ nagios_dell_omsa_pkg_state }} force=yes update_cache=yes cache_valid_time=1800
|
apt: pkg=syscfg state={{ nagios_dell_omsa_pkg_state }} force=yes update_cache=yes cache_valid_time=1800
|
||||||
with_items:
|
|
||||||
- syscfg
|
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Install the Dell OMSA packages
|
- name: Install the Dell OMSA packages
|
||||||
apt: pkg={{ item }} state={{ nagios_dell_omsa_pkg_state }} force=yes update_cache=yes cache_valid_time=1800
|
apt: pkg={{ nagios_dell_omsa_pkgs }} state={{ nagios_dell_omsa_pkg_state }} force=yes update_cache=yes cache_valid_time=1800
|
||||||
with_items: '{{ nagios_dell_omsa_pkgs }}'
|
|
||||||
notify: Start Dell OMSA
|
notify: Start Dell OMSA
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Install some standalone plugins
|
- name: Install some standalone plugins
|
||||||
copy: src={{ item }} dest={{ nagios_local_plugdir }}/{{ item }} owner=root group=nagios mode=0750
|
copy: src={{ nagios_dell_standalone_checks }} dest={{ nagios_local_plugdir }}/{{ item }} owner=root group=nagios mode=0750
|
||||||
with_items: '{{ nagios_dell_standalone_checks }}'
|
|
||||||
tags: [ 'dell', 'nagios' ]
|
tags: [ 'dell', 'nagios' ]
|
||||||
|
|
||||||
- name: Install a cron job that removes the leaked semaphores created by the nagios check of Dell hardware status
|
- name: Install a cron job that removes the leaked semaphores created by the nagios check of Dell hardware status
|
||||||
|
|
|
@ -9,9 +9,7 @@
|
||||||
- nagios
|
- nagios
|
||||||
|
|
||||||
- name: Install some packages needed by the hardware checks
|
- name: Install some packages needed by the hardware checks
|
||||||
apt: pkg={{ item }} state=present
|
apt: pkg=smartmontools state=present
|
||||||
with_items:
|
|
||||||
- smartmontools
|
|
||||||
tags:
|
tags:
|
||||||
- nagios-hw
|
- nagios-hw
|
||||||
- nagios
|
- nagios
|
||||||
|
|
|
@ -1,12 +1,10 @@
|
||||||
---
|
---
|
||||||
- name: Install the nagios packages
|
- name: Install the nagios packages
|
||||||
apt: pkg={{ item }} state=present update_cache=yes cache_valid_time=1800
|
apt: pkg={{ nagios_plugins_base_pkgs }} state=present update_cache=yes cache_valid_time=1800
|
||||||
with_items: '{{ nagios_plugins_base_pkgs }}'
|
|
||||||
tags: nagios
|
tags: nagios
|
||||||
|
|
||||||
- name: Additional nagios plugins when available
|
- name: Additional nagios plugins when available
|
||||||
apt: pkg={{ item }} state=present update_cache=yes cache_valid_time=1800
|
apt: pkg={{ nagios_plugins_contrib }} state=present update_cache=yes cache_valid_time=1800
|
||||||
with_items: '{{ nagios_plugins_contrib }}'
|
|
||||||
tags: [ 'nagios', 'nagios_plug_contrib' ]
|
tags: [ 'nagios', 'nagios_plug_contrib' ]
|
||||||
|
|
||||||
- name: Create the directory where our local plugins are installed
|
- name: Create the directory where our local plugins are installed
|
||||||
|
|
|
@ -1,19 +1,8 @@
|
||||||
---
|
---
|
||||||
- name: Configure the nsca client
|
- name: Configure the nsca client
|
||||||
template: src=send_nsca.j2 dest=/etc/send_nsca.cfg owner=root group=root mode=400
|
template: src=send_nsca.j2 dest=/etc/send_nsca.cfg owner=root group=root mode=400
|
||||||
tags:
|
tags: nsca
|
||||||
- nsca
|
|
||||||
|
|
||||||
- apt: pkg={{ item }} state=present
|
- apt: pkg=nsca-client state=present
|
||||||
with_items:
|
tags: nsca
|
||||||
- nsca-client
|
|
||||||
when: '(({{ is_not_ubuntu_less_than_precise }}) == True) or (({{ is_debian7 }}) == True)'
|
|
||||||
tags:
|
|
||||||
- nsca
|
|
||||||
|
|
||||||
- apt: pkg={{ item }} state=present
|
|
||||||
with_items:
|
|
||||||
- nsca
|
|
||||||
when: "(({{ is_not_debian_less_than_6 }}) == True) and (({{ is_ubuntu_less_than_precise }}) == True)"
|
|
||||||
tags:
|
|
||||||
- nsca
|
|
||||||
|
|
|
@ -12,9 +12,7 @@
|
||||||
- nagios
|
- nagios
|
||||||
|
|
||||||
- name: Install the packages needed to check postgres via nagios
|
- name: Install the packages needed to check postgres via nagios
|
||||||
apt: pkg={{ item }} state=present
|
apt: pkg=check-postgres state=present
|
||||||
with_items:
|
|
||||||
- check-postgres
|
|
||||||
tags:
|
tags:
|
||||||
- nrpe
|
- nrpe
|
||||||
- nagios
|
- nagios
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#
|
#
|
||||||
command[global_check_disk]={{ nagios_plugins_dir }}/check_disk -w {{ nagios_check_disk_w }}% -c {{ nagios_check_disk_c }}% -X tmpfs -X proc -X sysfs -X devpts -X dev -A -i /mnt/.*
|
command[global_check_disk]={{ nagios_plugins_dir }}/check_disk -w {{ nagios_check_disk_w }}% -c {{ nagios_check_disk_c }}% -X tmpfs -X proc -X sysfs -X devpts -X dev -A -i "/mnt/.*" {% if nagios_additional_checkdisk_options is defined %} {{ nagios_additional_checkdisk_options }} {% endif %}
|
||||||
|
|
||||||
command[global_check_load]={{ nagios_plugins_dir }}/check_load {% if nagios_load_per_cpu %}-r{% endif %} -w {{ nagios_load_w }} -c {{ nagios_load_c }}
|
command[global_check_load]={{ nagios_plugins_dir }}/check_load {% if nagios_load_per_cpu %}-r{% endif %} -w {{ nagios_load_w }} -c {{ nagios_load_c }}
|
||||||
{% if ansible_distribution_release == 'xenial' %}
|
{% if ansible_distribution_release == 'xenial' %}
|
||||||
|
|
Loading…
Reference in New Issue