aboutsummaryrefslogtreecommitdiff
path: root/modules/private/monitoring/objects_quatresaisons.nix
diff options
context:
space:
mode:
Diffstat (limited to 'modules/private/monitoring/objects_quatresaisons.nix')
-rw-r--r--modules/private/monitoring/objects_quatresaisons.nix19
1 files changed, 17 insertions, 2 deletions
diff --git a/modules/private/monitoring/objects_quatresaisons.nix b/modules/private/monitoring/objects_quatresaisons.nix
index 55d5631..f30cf81 100644
--- a/modules/private/monitoring/objects_quatresaisons.nix
+++ b/modules/private/monitoring/objects_quatresaisons.nix
@@ -1,4 +1,4 @@
1{ lib, hostFQDN, emailCheck, ... }: 1{ lib, hostFQDN, emailCheck, openldap, ... }:
2let 2let
3 defaultPassiveInfo = { 3 defaultPassiveInfo = {
4 filter = lib.attrsets.filterAttrs 4 filter = lib.attrsets.filterAttrs
@@ -11,7 +11,10 @@ let
11 }; 11 };
12in 12in
13{ 13{
14 activatedPlugins = [ "megaraid" ]; 14 resources = {
15 USER212 = "{{ .monitoring.quatresaisons.naemon_ldap }}";
16 };
17 activatedPlugins = [ "megaraid" "command" "postgresql" ];
15 service = [ 18 service = [
16 { 19 {
17 passiveInfo = defaultPassiveInfo // { servicegroups = "webstatus-resources"; }; 20 passiveInfo = defaultPassiveInfo // { servicegroups = "webstatus-resources"; };
@@ -19,5 +22,17 @@ in
19 use = "local-service"; 22 use = "local-service";
20 check_command = ["check_megaraid"]; 23 check_command = ["check_megaraid"];
21 } 24 }
25 {
26 passiveInfo = defaultPassiveInfo // { servicegroups = "webstatus-resources"; };
27 service_description = "LDAP is running";
28 use = "local-service";
29 check_command = [ "check_command_status" "${openldap}/bin/ldapwhoami -D uid=naemon,ou=services,dc=salle-s,dc=org -w $USER212$" "0" ""];
30 }
31 {
32 passiveInfo = defaultPassiveInfo // { servicegroups = "webstatus-resources"; };
33 service_description = "Postgresql is running";
34 use = "local-service";
35 check_command = [ "check_postgresql_database_count" "/run/postgresql" "5432" "3" ];
36 }
22 ]; 37 ];
23} 38}