summaryrefslogtreecommitdiffstats
path: root/zones.d/global-templates/services.conf
diff options
context:
space:
mode:
authorTobias Wiese <tobias@tobiaswiese.com>2020-05-11 20:38:42 +0200
committerTobias Wiese <tobias@tobiaswiese.com>2020-05-11 20:38:42 +0200
commit0ca93dff41ff3a9889a5847ff0f854cf5cef1185 (patch)
tree6ac88c0d6125112a6b63d10d6e72861e60aead62 /zones.d/global-templates/services.conf
parent50be889b75116ae5b36ea9113e79649df16c6986 (diff)
service: basic node health
Check for basic node health including ping, disk and swap. Also check with the package manager, that the system is up to date. Signed-off-by: Tobias Wiese <tobias@tobiaswiese.com>
Diffstat (limited to 'zones.d/global-templates/services.conf')
-rw-r--r--zones.d/global-templates/services.conf57
1 files changed, 57 insertions, 0 deletions
diff --git a/zones.d/global-templates/services.conf b/zones.d/global-templates/services.conf
new file mode 100644
index 0000000..9081f19
--- /dev/null
+++ b/zones.d/global-templates/services.conf
@@ -0,0 +1,57 @@
+template Service "generic-service" { }
+
+
+/**
+ * Basic node health checks
+ */
+
+apply Service "disk" {
+ import "generic-service"
+
+ check_command = "disk"
+
+ assign where host.vars.kernel == "linux"
+}
+
+apply Service "icinga" {
+ import "generic-service"
+
+ check_command = "icinga"
+
+ assign where host.vars.kernel == "linux"
+}
+
+apply Service "load" {
+ import "generic-service"
+
+ check_command = "load"
+
+ assign where host.vars.kernel == "linux"
+}
+
+apply Service "procs" {
+ import "generic-service"
+
+ check_command = "procs"
+
+ assign where host.vars.kernel == "linux"
+}
+
+apply Service "swap" {
+ import "generic-service"
+
+ check_command = "swap"
+
+ assign where host.vars.kernel == "linux"
+}
+
+/* OS specific basic health checks */
+apply Service "apt" {
+ import "generic-service"
+
+ check_command = "apt"
+
+ volatile = true
+
+ assign where host.vars.os_family == "debian"
+}