pn_vrouter - CLI command to create/delete/modify a vrouter.¶
New in version 2.2.
Synopsis¶
- Execute vrouter-create, vrouter-delete, vrouter-modify command.
- Each fabric, cluster, standalone switch, or virtual network (VNET) can provide its tenants with a virtual router (vRouter) service that forwards traffic between networks and implements Layer 3 protocols.
vrouter-create
creates a new vRouter service.vrouter-delete
deletes a vRouter service.vrouter-modify
modifies a vRouter service.
Parameters¶
Parameter | Choices/Defaults | Comments |
---|---|---|
pn_bgp_as |
Specify the Autonomous System Number(ASN) if the vRouter runs Border Gateway Protocol(BGP).
|
|
pn_bgp_max_paths |
Specify the maximum number of paths for BGP. This is a number between 1 and 255 or 0 to unset.
|
|
pn_bgp_options |
Specify other BGP options as a whitespaces separated string within single quotes ''.
|
|
pn_bgp_redistribute |
|
Specify how BGP routes are redistributed.
|
pn_clipassword |
Provide login password if user is not root.
|
|
pn_cliswitch |
Target switch(es) to run the CLI on.
|
|
pn_cliusername |
Provide login username if user is not root.
|
|
pn_hw_vrrp_id |
Specifies the VRRP ID for a hardware vrouter.
|
|
pn_name
required |
Specify the name of the vRouter.
|
|
pn_ospf_options |
Specify other OSPF options as a whitespaces separated string within single quotes ''.
|
|
pn_ospf_redistribute |
|
Specify how OSPF routes are redistributed.
|
pn_rip_redistribute |
|
Specify how RIP routes are redistributed.
|
pn_router_id |
Specify the vRouter IP address.
|
|
pn_router_type |
|
Specify if the vRouter uses software or hardware.
Note that if you specify hardware as router type, you cannot assign IP addresses using DHCP. You must specify a static IP address.
|
pn_service_state |
|
Specify to enable or disable vRouter service.
|
pn_service_type |
|
Specify if the vRouter is a dedicated or shared VNET service.
|
pn_vnet |
Specify the name of the VNET.
Required for vrouter-create.
|
|
state
required |
|
State the action to perform. Use 'present' to create vrouter, 'absent' to delete vrouter and 'update' to modify vrouter.
|
Examples¶
- name: create vrouter
pn_vrouter:
state: 'present'
pn_name: 'ansible-vrouter'
pn_vnet: 'ansible-fab-global'
pn_router_id: 208.74.182.1
- name: delete vrouter
pn_vrouter:
state: 'absent'
pn_name: 'ansible-vrouter'
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
changed
bool
|
always |
Indicates whether the CLI caused changes on the target.
|
command
str
|
always |
The CLI command run on the target node(s).
|
stderr
list
|
on error |
The set of error responses from the vrouter command.
|
stdout
list
|
always |
The set of responses from the vrouter command.
|
Status¶
This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.
Maintenance¶
This module is flagged as community which means that it is maintained by the Ansible Community. See Module Maintenance & Support for more info.
For a list of other modules that are also maintained by the Ansible Community, see here.
Author¶
- Pluribus Networks (@amitsi)
Hint
If you notice any issues in this documentation you can edit this document to improve it.