Skip to content

Commit 15874ca

Browse files
Merge branch 'main' into test_integration
2 parents 1329c27 + 4957938 commit 15874ca

4 files changed

Lines changed: 51 additions & 3 deletions

File tree

plugins/module_utils/common.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -619,6 +619,8 @@ def get_valid_desired_states(resource_name):
619619
desired_states.add("switched")
620620
if "unset" in supported_operations:
621621
desired_states.add("unset")
622+
if "Install" in supported_operations or "install" in supported_operations:
623+
desired_states.add("installed")
622624
if "rename" in supported_operations:
623625
desired_states.add("renamed")
624626
if "apply" in supported_operations:

plugins/module_utils/module_executor.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -372,6 +372,14 @@ def is_resource_identical(self):
372372

373373
return (False, None) if diff_list else (True, None)
374374

375+
@trace
376+
def install(self):
377+
ok, err = create_resource(
378+
self.client, self.resource_name, self.resource_module_params
379+
)
380+
if not ok:
381+
self.return_failure(err)
382+
375383
@trace
376384
def create_or_update(self):
377385
self.update_diff_list(
@@ -964,6 +972,9 @@ def main(self):
964972
if "bindings" in NITRO_RESOURCE_MAP[self.resource_name].keys():
965973
self.sync_all_bindings()
966974

975+
elif self.resource_name == "install" and self.module.params["state"] == "installed":
976+
self.install()
977+
967978
elif self.module.params["state"] in {
968979
"created",
969980
"imported",

plugins/module_utils/nitro_resource_map.py

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19002,6 +19002,30 @@
1900219002
"singleton": False,
1900319003
"update_payload_keys": [],
1900419004
},
19005+
"clear_config": {
19006+
"_supported_operations": ["add"],
19007+
"add_payload_keys": ["all", "mode"],
19008+
"bindings": [],
19009+
"bindprimary_key": "",
19010+
"delete_arg_keys": [],
19011+
"disable_payload_keys": [],
19012+
"enable_payload_keys": [],
19013+
"get_arg_keys": [],
19014+
"immutable_keys": [],
19015+
"primary_key": "",
19016+
"primary_key_composite": [],
19017+
"readwrite_arguments": {
19018+
"all": {"no_log": False, "required": False, "type": "bool"},
19019+
"mode": {
19020+
"choices": ["basic", "extended+", "full"],
19021+
"no_log": False,
19022+
"required": False,
19023+
"type": "str",
19024+
},
19025+
},
19026+
"singleton": False,
19027+
"update_payload_keys": [],
19028+
},
1900519029
"cloudallowedngsticketprofile": {
1900619030
"_supported_operations": [
1900719031
"add",
@@ -30203,6 +30227,15 @@
3020330227
"create": [],
3020430228
"force": [],
3020530229
"import": [],
30230+
"install": [
30231+
"a",
30232+
"async",
30233+
"enhancedupgrade",
30234+
"l",
30235+
"resizeswapvar",
30236+
"url",
30237+
"y",
30238+
],
3020630239
"link": [],
3020730240
"switch": [],
3020830241
"unlink": [],

plugins/modules/install.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,19 +19,21 @@
1919
DOCUMENTATION = r"""
2020
---
2121
module: install
22-
short_description: Configuration for 0 resource.
23-
description: Configuration for 0 resource.
22+
short_description: Configuration for install resource.
23+
description: Configuration for install resource.
2424
version_added: 2.0.0
2525
author:
2626
- Sumanth Lingappa (@sumanth-lingappa)
2727
- Shiva Shankar Vaddepally (@shivashankar-vaddepally)
2828
options:
2929
state:
30-
choices: []
30+
choices:
31+
- installed
3132
default: present
3233
description:
3334
- The state of the resource being configured by the module on the NetScaler
3435
ADC node.
36+
- When C(Install), the resource will be installed on the NetScaler ADC node.
3537
type: str
3638
async:
3739
type: bool

0 commit comments

Comments
 (0)