Skip to content

Commit

Permalink
The VLAN ID type has been updated to be handled as an integer
Browse files Browse the repository at this point in the history
  • Loading branch information
sky-joker committed Dec 5, 2024
1 parent 290bc26 commit 1a79e72
Showing 1 changed file with 34 additions and 3 deletions.
37 changes: 34 additions & 3 deletions plugins/modules/vmware_dvswitch_pvlans.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,12 @@
type: list
default: []
elements: dict
suboptions:
primary_pvlan_id:
description:
- The primary VLAN ID.
- The VLAN IDs of 0 and 4095 are reserved and cannot be used in this option.
type: int
secondary_pvlans:
description:
- A list of VLAN IDs that should be configured as Secondary PVLANs.
Expand All @@ -46,9 +52,26 @@
type: list
default: []
elements: dict
suboptions:
primary_pvlan_id:
description:
- The primary VLAN ID.
- The VLAN IDs of 0 and 4095 are reserved and cannot be used in this option.
type: int
secondary_pvlan_id:
description:
- The type of PVLAN.
type: int
pvlan_type:
description:
- The secondary VLAN ID.
- The VLAN IDs of 0 and 4095 are reserved and cannot be used in this option.
choices:
- community
- isolated
type: str
extends_documentation_fragment:
- community.vmware.vmware.documentation
'''

EXAMPLES = r'''
Expand Down Expand Up @@ -509,8 +532,16 @@ def main():
argument_spec.update(
dict(
switch=dict(required=True, aliases=['dvswitch']),
primary_pvlans=dict(type='list', default=list(), elements='dict'),
secondary_pvlans=dict(type='list', default=list(), elements='dict'),
primary_pvlans=dict(type='list', default=list(), elements='dict',
options=dict(
primary_pvlan_id=dict(type='int')
)),
secondary_pvlans=dict(type='list', default=list(), elements='dict',
options=dict(
primary_pvlan_id=dict(type='int'),
secondary_pvlan_id=dict(type='int'),
pvlan_type=dict(type='str', choices=['community', 'isolated'])
)),
)
)

Expand Down

0 comments on commit 1a79e72

Please sign in to comment.