Created
July 5, 2014 17:32
-
-
Save dnsmichi/ee485d8097531dbd3344 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'...' means something is missing | |
object Host "checkper1" { | |
import ... | |
check_period = "8x5" //apply rule matches | |
groups = [ "foo-server" ] | |
... | |
vars.has_custom_check_period = true //could be used too for apply match | |
} | |
object Host "normal" { | |
import ... | |
groups = [ "foo-server" ] | |
} | |
//8x5 service | |
apply Service "svc1" { | |
import ... | |
check_period = "8x5" //same as host | |
assign where "foo-server" in host.groups && host.check_period == "8x5" | |
ignore where ... | |
} | |
//normal service | |
apply Service "svc1" { | |
import ... | |
assign where "foo-server" in host.groups | |
ignore where host.check_period != "24x7" //if there's a custom check period, don't apply the default check period | |
} | |
//untested! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment