Thank you very much, both works as expected!
Am 11/26/2016 um 10:04 PM schrieb Thomas Gelf:
Hi Dirk!
Am 26.11.2016 um 21:54 schrieb Dirk Roeder:
command = [ PluginDir + "/debug" + "-v"]
I guess this is what you're looking for:
command = [ PluginDir + "/debug", "-v"]
* How can I append empty arguments based on a variable content? So I
could use 2 different variables, but for this checks it is one of two
possible values, so I would like to use only one.
I didn't try it, but this should work:
arguments = {
"-foo" = {
set_if = {{ return macro("$valtest$") == "foo }}
}
"-bar" = {
set_if = {{ return macro("$valtest$") == "foo }}
}
}
The main reason why your tests didn't work as expected is that the code
in set_if is executed in a completely different context later on.
Cheers,
Thomas
--
Thomas Gelf
Principal Consultant
NETWAYS GmbH | Deutschherrnstr. 15-19 | D-90429 Nuernberg
Tel: +49 911 92885-0 | Fax: +49 911 92885-77
CEO: Julian Hein, Bernd Erk | AG Nuernberg HRB18461
http://www.netways.de | thomas.g...@netways.de
** OSMC 2016 - November - netways.de/osmc **
** OSDC 2017 - Mai – osdc.de **
_______________________________________________
icinga-users mailing list
icinga-users@lists.icinga.org
https://lists.icinga.org/mailman/listinfo/icinga-users
_______________________________________________
icinga-users mailing list
icinga-users@lists.icinga.org
https://lists.icinga.org/mailman/listinfo/icinga-users