Skip to content

Commit f751b9a

Browse files
authored
split vpn param that can accept either a String or list of objects to two (#109)
* Add new nat module * Support nat-rule relative positioning + bug fix * New Resource Modules * split vpn param that can accept either a String or list of objects to two
1 parent 0d99b91 commit f751b9a

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

plugins/modules/cp_mgmt_access_rules.py

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@
210210
description:
211211
- N/A
212212
type: str
213-
vpn:
213+
vpn_list:
214214
description:
215215
- Communities or Directional.
216216
type: list
@@ -220,7 +220,7 @@
220220
description:
221221
- List of community name or UID.
222222
type: list
223-
elements: dict
223+
elements: str
224224
directional:
225225
description:
226226
- Communities directional match condition.
@@ -235,6 +235,11 @@
235235
description:
236236
- To community name or UID.
237237
type: str
238+
vpn:
239+
description:
240+
- Any or All_GwToGw.
241+
type: str
242+
choices: ['Any', 'All_GwToGw']
238243
comments:
239244
description:
240245
- Comments string.
@@ -401,18 +406,19 @@ def main():
401406
interaction=dict(type="str"),
402407
),
403408
),
404-
vpn=dict(
409+
vpn_list=dict(
405410
type="list",
406411
elements="dict",
407412
options=dict(
408-
community=dict(type="list", elements="dict"),
413+
community=dict(type="list", elements="str"),
409414
directional=dict(
410415
type="list",
411416
elements="dict",
412417
options=dict(to=dict(type="str")),
413418
),
414419
),
415420
),
421+
vpn=dict(type="str", choices=["Any", "All_GwToGw"]),
416422
comments=dict(type="str"),
417423
details_level=dict(
418424
type="str", choices=["uid", "standard", "full"]
@@ -430,7 +436,7 @@ def main():
430436
details_level=dict(type="str", choices=["uid", "standard", "full"]),
431437
)
432438

433-
argument_spec["rules"]["options"]["vpn"]["options"]["directional"][
439+
argument_spec["rules"]["options"]["vpn_list"]["options"]["directional"][
434440
"options"
435441
]["from"] = dict(type="str")
436442
argument_spec.update(checkpoint_argument_spec_for_action_module)

0 commit comments

Comments
 (0)