diff --git a/global-templates/commands.conf b/global-templates/commands.conf index 3ebd37d..32610d1 100644 --- a/global-templates/commands.conf +++ b/global-templates/commands.conf @@ -103,3 +103,7 @@ object CheckCommand "pgsql_socket" { vars.pgsql_username = "nagios" } + +object CheckCommand "systemd" { + command = [ PluginContribDir + "/check_systemd" ] +} diff --git a/global-templates/host-templates.conf b/global-templates/host-templates.conf index 8de3906..28c4da1 100644 --- a/global-templates/host-templates.conf +++ b/global-templates/host-templates.conf @@ -20,6 +20,10 @@ template Host "linux-host" { import "generic-host" vars.os = "Linux" + + vars.disks["/"] = { + disk_partitions = "/" + } } template Host "debian-host" { diff --git a/global-templates/services.conf b/global-templates/services.conf index b987292..217967a 100644 --- a/global-templates/services.conf +++ b/global-templates/services.conf @@ -150,6 +150,14 @@ apply Service "ssh" { assign where (host.address || host.address6) && host.vars.os == "Linux" && !host.vars.no_check_ssh } +apply Service "systemd" { + import "generic-service" + + check_command = "systemd" + + assign where host.vars.debian_release && host.vars.debian_release >= 12 +} + apply Service "users" { import "generic-service" diff --git a/master/hosts.conf b/master/hosts.conf index d853e7a..ac3d45c 100644 --- a/master/hosts.conf +++ b/master/hosts.conf @@ -9,10 +9,8 @@ object Host "beholder" { address6 = "::1" vars.is_container = false + vars.debian_release = 12 - vars.disks["/"] = { - disk_partitions = "/" - } vars.disks["/boot/efi"] = { disk_partitions = "/boot/efi" }