summaryrefslogtreecommitdiff
path: root/manifests/service/ping.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/service/ping.pp')
-rw-r--r--manifests/service/ping.pp16
1 files changed, 6 insertions, 10 deletions
diff --git a/manifests/service/ping.pp b/manifests/service/ping.pp
index c705c68..f1c8d87 100644
--- a/manifests/service/ping.pp
+++ b/manifests/service/ping.pp
@@ -1,13 +1,9 @@
define nagios::service::ping(
- $ensure = present
+ $ensure = present,
+ $ping_rate = '!100.0,20%!500.0,60%'
){
- $real_nagios_ping_rate = $nagios_ping_rate ? {
- '' => '!100.0,20%!500.0,60%',
- default => $nagios_ping_rate
- }
-
- nagios::service{ "check_ping":
- ensure => $ensure,
- check_command => "check_ping${real_nagios_ping_rate}",
- }
+ nagios::service{ "check_ping":
+ ensure => $ensure,
+ check_command => "check_ping${ping_rate}",
+ }
}