I have a CheckCommand defined in Icinga2 that looks like this:
object CheckCommand "foo" {
import "plugin-check-command"
command = [ "/opt/my_plugins/check_foo" ]
arguments = {
"-a" = {
value = "$foo_a$"
description = "Parameter A"
}
"-b" = {
value = "$foo_b$"
description = "Parameter B"
}
vars.foo_a = "$a$"
vars.foo_b = "$b$"
}
Either a, or b, or both are required by the command, but it cannot run if it doesn't get at least one of those parameters. I'd like to express this requirement in the Icinga2 command definition, is it possible?