aboutsummaryrefslogtreecommitdiff
path: root/modules/profile/manifests/monitoring/services.pp
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2018-07-11 09:31:24 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2018-07-11 09:31:24 +0200
commit2bdbb0213a0f70705f81ac2eaf8349668b2c29b4 (patch)
tree06b1e40db99815133dcc40e3e68531d45e1bd228 /modules/profile/manifests/monitoring/services.pp
parent25c99a635507abfe6af4a1f0a9fc5a103d1880c0 (diff)
parentd8bc769648c1528f5d749deee060d70e326ef431 (diff)
downloadPuppet-2bdbb0213a0f70705f81ac2eaf8349668b2c29b4.tar.gz
Puppet-2bdbb0213a0f70705f81ac2eaf8349668b2c29b4.tar.zst
Puppet-2bdbb0213a0f70705f81ac2eaf8349668b2c29b4.zip
Merge branch 'monitoring' into dev
Diffstat (limited to 'modules/profile/manifests/monitoring/services.pp')
-rw-r--r--modules/profile/manifests/monitoring/services.pp42
1 files changed, 42 insertions, 0 deletions
diff --git a/modules/profile/manifests/monitoring/services.pp b/modules/profile/manifests/monitoring/services.pp
new file mode 100644
index 0000000..95c6efb
--- /dev/null
+++ b/modules/profile/manifests/monitoring/services.pp
@@ -0,0 +1,42 @@
1class profile::monitoring::services {
2
3 profile::monitoring::local_service {
4 "Size on root partition":
5 local => {
6 check_command => "check_local_disk!20%!10%!/",
7 };
8 "Total number of process":
9 local => {
10 check_command => "check_local_procs!50!100!RSZDT",
11 };
12 "Average load":
13 local => {
14 check_command => "check_local_load!8.0,8.0,8.0!10.0,10.0,10.0",
15 };
16 "Swap usage":
17 local => {
18 check_command => "check_local_swap!20!10",
19 };
20 "fail2ban is active":
21 sudos => {
22 "naemon-fail2ban" => "naemon ALL=(root) NOPASSWD: /usr/bin/fail2ban-client ping",
23 },
24 local => {
25 check_command => "check_command_output!fail2ban-client ping!pong!-r root",
26 };
27 "NTP is activated and working":
28 local => {
29 check_command => "check_ntp",
30 };
31 "No mdadm array is degraded":
32 common => {
33 ensure => (find_file("/proc/mdstat") == undef) ? { true => "absent", default =>"present" },
34 },
35 local => {
36 check_command => "check_md_raid",
37 };
38 }
39
40 Profile::Monitoring::Local_service <| |>
41 Profile::Monitoring::External_service <| |>
42}