summaryrefslogtreecommitdiffstats
path: root/zones.d/global-templates
diff options
context:
space:
mode:
authorTobias Wiese <tobias@tobiaswiese.com>2020-05-14 23:16:48 +0200
committerTobias Wiese <tobias@tobiaswiese.com>2020-05-14 23:16:48 +0200
commitd6e394443554fd987101edeacec8c37853fdfdc8 (patch)
tree2cd67b235167c5e9ef5724eec80b1436e3e5abbc /zones.d/global-templates
parent1d3f54ef5966e8b10304f0ed364a7ad7d3a9c73f (diff)
hosts/keen-morse: Monitor the mailserver
Add monitoring to the mailserver. Alos adds services for the mailq, smtp and imap Signed-off-by: Tobias Wiese <tobias@tobiaswiese.com>
Diffstat (limited to 'zones.d/global-templates')
-rw-r--r--zones.d/global-templates/services.conf20
1 files changed, 19 insertions, 1 deletions
diff --git a/zones.d/global-templates/services.conf b/zones.d/global-templates/services.conf
index 825b9fe..d86a7a0 100644
--- a/zones.d/global-templates/services.conf
+++ b/zones.d/global-templates/services.conf
@@ -42,6 +42,8 @@ apply Service "swap" {
check_command = "swap"
+ vars.swap_noswap = "ok"
+
assign where host.vars.kernel == "linux"
}
@@ -57,9 +59,25 @@ apply Service "apt" {
}
/**
- * Serice health checks
+ * Service health checks
*/
+apply Service "mailq" {
+ import "generic-service"
+
+ check_command = "mailq"
+
+ vars += {
+ mailq_warning = 50
+ mailq_critical = 55
+ mailq_domain_warning = 30
+ mailq_domain_critical = 35
+ mailq_servertype = host.vars.mailserver
+ }
+
+ assign where host.vars.mailserver
+}
+
apply Service "pgsql" {
import "generic-service"