From 5ae1f30abda34877328c82b354d1597e46c43ad9 Mon Sep 17 00:00:00 2001 From: "Jehan-Guillaume (ioguix) de Rorthais" Date: Fri, 16 Jul 2021 12:42:06 +0200 Subject: [PATCH] Add some more documentation on command template (#128) * Add some more documentation on command template * Fix doc syntax in plugins/modules/icinga_command_template.py Co-authored-by: Sebastian Gumprich Co-authored-by: Sebastian Gumprich --- plugins/modules/icinga_command_template.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/plugins/modules/icinga_command_template.py b/plugins/modules/icinga_command_template.py index ef12b9f7..0d23eff4 100644 --- a/plugins/modules/icinga_command_template.py +++ b/plugins/modules/icinga_command_template.py @@ -90,6 +90,12 @@ arguments: description: - Arguments of the command template. + - Each argument can take either a string, a json or a dict + - When using a dict as argument value, the following properties are supported. + C(skip_key), C(repeat_key), C(required), C(order), C(description)), + C(set_if), C(value). + - The C(value) property can be either a string, a json or a dict. When used as a dict, you can define + its C(type) as C(Function) and set its C(body) property as an Icinga DSL piece of config. type: "dict" """ @@ -135,6 +141,11 @@ set_if: $centreon_verbose$ '--warning': value: $centreon_warning$ + '--dummy-arg': + description: "dummy arg using Icinga DSL code" + value: + type: "Function" + body: 'return macro("$dummy_var$")' command: "/opt/centreon-plugins/centreon_plugins.pl" command_type: "PluginCheck" object_name: centreon-plugins-template