New in version 2.2.
parameter | required | default | choices | comments |
---|---|---|---|---|
pn_clipassword |
no | Provide login password if user is not root. | ||
pn_cliswitch |
no | Target switch(es) to run the cli on. | ||
pn_cliusername |
no | Provide login username if user is not root. | ||
pn_description |
no | Specify a description for the VLAN. | ||
pn_ports |
no | Specifies the switch network data port number, list of ports, or range of ports. Port numbers must ne in the range of 1 to 64. | ||
pn_scope |
no |
|
Specify a scope for the VLAN. Required for vlan-create. | |
pn_stats |
no | Specify if you want to collect statistics for a VLAN. Statistic collection is enabled by default. | ||
pn_untagged_ports |
no | Specifies the ports that should have untagged packets mapped to the VLAN. Untagged packets are packets that do not contain IEEE 802.1Q VLAN tags. | ||
pn_vlanid |
yes | Specify a VLAN identifier for the VLAN. This is a value between 2 and 4092. | ||
state |
yes |
|
State the action to perform. Use 'present' to create vlan and 'absent' to delete vlan. |
- name: create a VLAN pn_vlan: state: 'present' pn_vlanid: 1854 pn_scope: fabric - name: delete VLANs pn_vlan: state: 'absent' pn_vlanid: 1854
Common return values are documented here Return Values, the following are the fields unique to this module:
name | description | returned | type | sample |
---|---|---|---|---|
changed | Indicates whether the CLI caused changes on the target. | always | bool | |
command | The CLI command run on the target node(s). | always | str | |
stderr | The set of error responses from the vlan command. | on error | list | |
stdout | The set of responses from the vlan command. | always | list |
This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.
This module is community maintained without core committer oversight.
For more information on what this means please read Module Support
For help in developing on modules, should you be so inclined, please read Community Information & Contributing, Helping Testing PRs and Developing Modules.