From 0ecaea3ac1780148a4360c8e798059e3ef9635d0 Mon Sep 17 00:00:00 2001 From: James Moore Date: Wed, 17 Feb 2016 18:04:39 -0800 Subject: [PATCH] Added a source parameter for setting the JIT client name --- lib/ansible/modules/extras/monitoring/sensu_check.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/ansible/modules/extras/monitoring/sensu_check.py b/lib/ansible/modules/extras/monitoring/sensu_check.py index f7f0562f48c..e880e9239d9 100644 --- a/lib/ansible/modules/extras/monitoring/sensu_check.py +++ b/lib/ansible/modules/extras/monitoring/sensu_check.py @@ -156,6 +156,12 @@ options: - You can't rewrite others module parameters using this required: false default: {} + source: + version_added: "2.1" + description: + - The check source, used to create a JIT Sensu client for an external resource (e.g. a network switch). + required: false + default: null requirements: [ ] author: "Anders Ingemann (@andsens)" ''' @@ -251,6 +257,7 @@ def sensu_check(module, path, name, state='present', backup=False): 'aggregate', 'low_flap_threshold', 'high_flap_threshold', + 'source', ] for opt in simple_opts: if module.params[opt] is not None: @@ -353,6 +360,7 @@ def main(): 'low_flap_threshold': {'type': 'int'}, 'high_flap_threshold': {'type': 'int'}, 'custom': {'type': 'dict'}, + 'source': {'type': 'str'}, } required_together = [['subdue_begin', 'subdue_end']]