| OLD | NEW |
| (Empty) |
| 1 node 'server4' { | |
| 2 include base, puppetmaster | |
| 3 | |
| 4 class {'nagios::client': | |
| 5 server_address => 'monitoring.adblockplus.org' | |
| 6 } | |
| 7 | |
| 8 class {'nagios::server': | |
| 9 domain => 'monitoring.adblockplus.org', | |
| 10 certificate => 'monitoring.adblockplus.org_sslcert.pem', | |
| 11 private_key => 'monitoring.adblockplus.org_sslcert.key', | |
| 12 is_default => 'true', | |
| 13 htpasswd_source => 'puppet:///modules/private/nagios-htpasswd', | |
| 14 admins => ['*'] | |
| 15 } | |
| 16 | |
| 17 if $::environment == 'development' { | |
| 18 nagios_contact {'root': | |
| 19 service_notification_period => '24x7', | |
| 20 host_notification_period => '24x7', | |
| 21 service_notification_options => 'w,u,c,r', | |
| 22 host_notification_options => 'd,r', | |
| 23 service_notification_commands => 'notify-service-by-email', | |
| 24 host_notification_commands => 'notify-host-by-email', | |
| 25 email => 'root@localhost' | |
| 26 } | |
| 27 | |
| 28 nagios_contactgroup {'admins': | |
| 29 alias => 'Nagios Administrators', | |
| 30 members => 'root' | |
| 31 } | |
| 32 } else { | |
| 33 nagios_contact {'abp-admins': | |
| 34 alias => 'Adblock Plus Administartors', | |
| 35 service_notification_period => '24x7', | |
| 36 host_notification_period => '24x7', | |
| 37 service_notification_options => 'w,u,c,r', | |
| 38 host_notification_options => 'd,r', | |
| 39 service_notification_commands => 'notify-service-by-email', | |
| 40 host_notification_commands => 'notify-host-by-email', | |
| 41 email => 'admins@adblockplus.org' | |
| 42 } | |
| 43 | |
| 44 nagios_contactgroup {'admins': | |
| 45 alias => 'Nagios Administrators', | |
| 46 members => 'abp-admins' | |
| 47 } | |
| 48 } | |
| 49 | |
| 50 nagios_command {'check_nrpe_timeout': | |
| 51 command_line => '/usr/lib/nagios/plugins/check_nrpe -H $HOSTADDRESS$ -c $ARG
1$ -t $ARG2$' | |
| 52 } | |
| 53 | |
| 54 nagios_command {'check_easylist_http': | |
| 55 command_line => '/usr/lib/nagios/plugins/check_http -S -I $HOSTADDRESS$ -H e
asylist-downloads.adblockplus.org -u /easylist.txt -k "Accept-Encoding: gzip,def
late" -e "HTTP/1.1 200 OK"' | |
| 56 } | |
| 57 | |
| 58 nagios_command {'check_notification_http': | |
| 59 command_line => '/usr/lib/nagios/plugins/check_http -S -I $HOSTADDRESS$ -H n
otification.adblockplus.org -u /notification.json -k "Accept-Encoding: gzip,defl
ate" -e "HTTP/1.1 200 OK"' | |
| 60 } | |
| 61 | |
| 62 nagios_host {'server_4.adblockplus.org': use => 'generic-host'} | |
| 63 nagios_host {'server_5.adblockplus.org': use => 'generic-host'} | |
| 64 nagios_host {'server_6.adblockplus.org': use => 'generic-host'} | |
| 65 nagios_host {'server_7.adblockplus.org': use => 'generic-host'} | |
| 66 nagios_host {'server_10.adblockplus.org': use => 'generic-host'} | |
| 67 nagios_host {'server_11.adblockplus.org': use => 'generic-host'} | |
| 68 nagios_host {'server_12.adblockplus.org': use => 'generic-host'} | |
| 69 nagios_host {'server_15.adblockplus.org': use => 'generic-host'} | |
| 70 nagios_host {'server_16.adblockplus.org': use => 'generic-host'} | |
| 71 nagios_host {'server_19.adblockplus.org': use => 'generic-host'} | |
| 72 nagios_host {'download1.adblockplus.org': use => 'generic-host'} | |
| 73 nagios_host {'filter1.adblockplus.org': use => 'generic-host'} | |
| 74 nagios_host {'filter2.adblockplus.org': use => 'generic-host'} | |
| 75 nagios_host {'filter3.adblockplus.org': use => 'generic-host'} | |
| 76 nagios_host {'filter4.adblockplus.org': use => 'generic-host'} | |
| 77 nagios_host {'filter5.adblockplus.org': use => 'generic-host'} | |
| 78 nagios_host {'filter6.adblockplus.org': use => 'generic-host'} | |
| 79 nagios_host {'filter7.adblockplus.org': use => 'generic-host'} | |
| 80 nagios_host {'filter8.adblockplus.org': use => 'generic-host'} | |
| 81 nagios_host {'filter9.adblockplus.org': use => 'generic-host'} | |
| 82 nagios_host {'filter10.adblockplus.org': use => 'generic-host'} | |
| 83 nagios_host {'filter11.adblockplus.org': use => 'generic-host'} | |
| 84 nagios_host {'filter12.adblockplus.org': use => 'generic-host'} | |
| 85 nagios_host {'filter13.adblockplus.org': use => 'generic-host'} | |
| 86 nagios_host {'filter14.adblockplus.org': use => 'generic-host'} | |
| 87 nagios_host {'filter15.adblockplus.org': use => 'generic-host'} | |
| 88 nagios_host {'filter16.adblockplus.org': use => 'generic-host'} | |
| 89 nagios_host {'filter17.adblockplus.org': use => 'generic-host'} | |
| 90 nagios_host {'filter18.adblockplus.org': use => 'generic-host'} | |
| 91 nagios_host {'filtermaster1.adblockplus.org': use => 'generic-host'} | |
| 92 nagios_host {'notification1.adblockplus.org': use => 'generic-host'} | |
| 93 nagios_host {'notification2.adblockplus.org': use => 'generic-host'} | |
| 94 nagios_host {'update1.adblockplus.org': use => 'generic-host'} | |
| 95 nagios_host {'web1.adblockplus.org': use => 'generic-host'} | |
| 96 nagios_host {'stats1.adblockplus.org': use => 'generic-host'} | |
| 97 nagios_host {'issues1.adblockplus.org': use => 'generic-host'} | |
| 98 nagios_host {'codereview1.adblockplus.org': use => 'generic-host'} | |
| 99 | |
| 100 nagios_hostgroup {'all': members => '*'} | |
| 101 nagios_hostgroup {'http-servers': members => 'server_4.adblockplus.org, server
_10.adblockplus.org, server_16.adblockplus.org, download1.adblockplus.org, updat
e1.adblockplus.org, web1.adblockplus.org, stats1.adblockplus.org, issues1.adbloc
kplus.org, codereview1.adblockplus.org'} | |
| 102 nagios_hostgroup {'filter-servers': members => 'server_5.adblockplus.org, serv
er_6.adblockplus.org, server_7.adblockplus.org, server_11.adblockplus.org, serve
r_12.adblockplus.org, server_15.adblockplus.org, server_19.adblockplus.org, filt
er1.adblockplus.org, filter2.adblockplus.org, filter3.adblockplus.org, filter4.a
dblockplus.org, filter5.adblockplus.org, filter6.adblockplus.org, filter7.adbloc
kplus.org, filter8.adblockplus.org, filter9.adblockplus.org, filter10.adblockplu
s.org, filter11.adblockplus.org, filter12.adblockplus.org, filter13.adblockplus.
org, filter14.adblockplus.org, filter15.adblockplus.org, filter16.adblockplus.or
g, filter17.adblockplus.org, filter18.adblockplus.org, notification1.adblockplus
.org, notification2.adblockplus.org'} | |
| 103 | |
| 104 nagios_service {'current-load': | |
| 105 use => 'generic-service', | |
| 106 hostgroup_name => 'all', | |
| 107 service_description => 'Current Load', | |
| 108 check_command => 'check_nrpe_1arg!check_load' | |
| 109 } | |
| 110 | |
| 111 nagios_service {'disk-space': | |
| 112 use => 'generic-service', | |
| 113 hostgroup_name => 'all', | |
| 114 service_description => 'Disk Space', | |
| 115 check_command => 'check_nrpe_1arg!check_disk' | |
| 116 } | |
| 117 | |
| 118 nagios_service {'total-processes': | |
| 119 use => 'generic-service', | |
| 120 hostgroup_name => 'all', | |
| 121 service_description => 'Total Processes', | |
| 122 check_command => 'check_nrpe_1arg!check_total_procs' | |
| 123 } | |
| 124 | |
| 125 nagios_service {'zombie-processes': | |
| 126 use => 'generic-service', | |
| 127 hostgroup_name => 'all', | |
| 128 service_description => 'Zombie Processes', | |
| 129 check_command => 'check_nrpe_1arg!check_zombie_procs' | |
| 130 } | |
| 131 | |
| 132 nagios_service {'ssh': | |
| 133 use => 'generic-service', | |
| 134 hostgroup_name => 'all', | |
| 135 service_description => 'SSH', | |
| 136 check_command => 'check_ssh' | |
| 137 } | |
| 138 | |
| 139 nagios_service {'http': | |
| 140 use => 'generic-service', | |
| 141 hostgroup_name => 'http-servers', | |
| 142 service_description => 'HTTP', | |
| 143 check_command => 'check_http' | |
| 144 } | |
| 145 | |
| 146 nagios_service {'easylist-http': | |
| 147 use => 'generic-service', | |
| 148 hostgroup_name => 'filter-servers', | |
| 149 service_description => 'HTTP', | |
| 150 check_command => 'check_easylist_http' | |
| 151 } | |
| 152 | |
| 153 nagios_service {'notification-http': | |
| 154 use => 'generic-service', | |
| 155 hostgroup_name => 'filter-servers', | |
| 156 service_description => 'HTTP', | |
| 157 check_command => 'check_notification_http' | |
| 158 } | |
| 159 | |
| 160 nagios_service {'bandwidth': | |
| 161 use => 'generic-service', | |
| 162 hostgroup_name => 'all', | |
| 163 service_description => 'Bandwidth', | |
| 164 check_command => 'check_nrpe_timeout!check_bandwidth!20', | |
| 165 first_notification_delay => '15' | |
| 166 } | |
| 167 | |
| 168 nagios_service {'connections': | |
| 169 use => 'generic-service', | |
| 170 hostgroup_name => 'all', | |
| 171 service_description => 'Connections', | |
| 172 check_command => 'check_nrpe_1arg!check_connections', | |
| 173 } | |
| 174 | |
| 175 nagios_service {'memory': | |
| 176 use => 'generic-service', | |
| 177 hostgroup_name => 'all', | |
| 178 service_description => 'Memory', | |
| 179 check_command => 'check_nrpe_1arg!check_memory', | |
| 180 } | |
| 181 } | |
| OLD | NEW |