summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
Diffstat (limited to 'manifests')
-rw-r--r--manifests/init.pp12
1 files changed, 10 insertions, 2 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index f9939df..da6aa8a 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -102,7 +102,7 @@ class nagios::base {
mode => 0755, owner => root, group => 0;
}
- nagios_command{
+ nagios::command{
ssh_port:
command_line => '$USER1$/check_ssh -p $ARG1$ $HOSTADDRESS$';
# from apache2.pp
@@ -112,7 +112,7 @@ class nagios::base {
check_dig2:
command_line => '$USER1$/check_dig -H $HOSTADDRESS$ -l $ARG1$ --record_type=$ARG2$';
check_ntp:
- command_line => '$USER1/check_ntp -H $HOSTADDRESS$ -w 0.5 -c 1';
+ command_line => '$USER1$/check_ntp -H $HOSTADDRESS$ -w 0.5 -c 1';
}
Nagios_command <<||>>
@@ -243,6 +243,14 @@ define nagios::extra_host($ip, $nagios_alias, $host_use = 'generic-host', $paren
}
}
+# just a wrapper to make the notify more easy
+define nagios::comand( $command_line ){
+ nagios_command{$name
+ command_line => $command,
+ notify => Service[nagios],
+ }
+}
+
define nagios::service(
$check_command,
$host_name = $fqdn,