Skip to content

Commit 5ae1f30

Browse files
ioguixrndmh3ro
andauthored
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 <rndmh3ro@users.noreply.github.com> Co-authored-by: Sebastian Gumprich <rndmh3ro@users.noreply.github.com>
1 parent 5eda3f9 commit 5ae1f30

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

plugins/modules/icinga_command_template.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,12 @@
9090
arguments:
9191
description:
9292
- Arguments of the command template.
93+
- Each argument can take either a string, a json or a dict
94+
- When using a dict as argument value, the following properties are supported.
95+
C(skip_key), C(repeat_key), C(required), C(order), C(description)),
96+
C(set_if), C(value).
97+
- The C(value) property can be either a string, a json or a dict. When used as a dict, you can define
98+
its C(type) as C(Function) and set its C(body) property as an Icinga DSL piece of config.
9399
type: "dict"
94100
"""
95101

@@ -135,6 +141,11 @@
135141
set_if: $centreon_verbose$
136142
'--warning':
137143
value: $centreon_warning$
144+
'--dummy-arg':
145+
description: "dummy arg using Icinga DSL code"
146+
value:
147+
type: "Function"
148+
body: 'return macro("$dummy_var$")'
138149
command: "/opt/centreon-plugins/centreon_plugins.pl"
139150
command_type: "PluginCheck"
140151
object_name: centreon-plugins-template

0 commit comments

Comments
 (0)