New in version 1.4.
Manage Open vSwitch ports
- ovs-vsctl
parameter | required | default | choices | comments |
---|---|---|---|---|
bridge |
yes | Name of bridge to manage | ||
external_ids (added in 2.0) |
no | Dictionary of external_ids applied to a port. | ||
port |
yes | Name of port to manage on the bridge | ||
set (added in 2.0) |
no | None | Set a single property on a port. | |
state |
no | present |
|
Whether the port should exist |
timeout |
no | 5 | How long to wait for ovs-vswitchd to respond |
# Creates port eth2 on bridge br-ex - openvswitch_port: bridge=br-ex port=eth2 state=present # Creates port eth6 and set ofport equal to 6. - openvswitch_port: bridge=bridge-loop port=eth6 state=present set="Interface eth6 ofport_request=6" # Assign interface id server1-vifeth6 and mac address 52:54:00:30:6d:11 # to port vifeth6 and setup port to be managed by a controller. - openvswitch_port: bridge=br-int port=vifeth6 state=present args: external_ids: iface-id: "{{inventory_hostname}}-vifeth6" attached-mac: "52:54:00:30:6d:11" vm-id: "{{inventory_hostname}}" iface-status: "active"
For more information on what this means please read Extras Modules
For help in developing on modules, should you be so inclined, please read Community Information & Contributing, Helping Testing PRs and Developing Modules.