summaryrefslogtreecommitdiff
path: root/manifests/service/http.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/service/http.pp')
-rw-r--r--manifests/service/http.pp4
1 files changed, 4 insertions, 0 deletions
diff --git a/manifests/service/http.pp b/manifests/service/http.pp
index 5fd9890..8fd5059 100644
--- a/manifests/service/http.pp
+++ b/manifests/service/http.pp
@@ -8,6 +8,7 @@ define nagios::service::http(
$check_domain = 'absent',
$check_url = '/',
$check_code = 'OK',
+ $use = 'generic-service',
$ssl_mode = false
){
$real_check_domain = $check_domain ? {
@@ -18,12 +19,14 @@ define nagios::service::http(
'force',true,'only': {
nagios::service{"https_${name}_${check_code}":
ensure => $ensure,
+ use => $use,
check_command => "check_https_url_regex!${real_check_domain}!${check_url}!'${check_code}'",
}
case $ssl_mode {
'force': {
nagios::service{"httprd_${name}":
ensure => $ensure,
+ use => $use,
check_command => "check_http_url_regex!${real_check_domain}!${check_url}!'301'",
}
}
@@ -34,6 +37,7 @@ define nagios::service::http(
false,true: {
nagios::service{"http_${name}_${check_code}":
ensure => $ensure,
+ use => $use,
check_command => "check_http_url_regex!${real_check_domain}!${check_url}!'${check_code}'",
}
}