diff --git a/overlays/bird/ovs-config.sh b/overlays/bird/ovs-config.sh new file mode 100755 index 0000000..86265c4 --- /dev/null +++ b/overlays/bird/ovs-config.sh @@ -0,0 +1,25 @@ +#!/bin/sh +# +# OVS configuration for the `bird` overlay + +LAB=${LAB:=0} +for node in 0 1 2 3; do + for int in 0 1 2 3; do + ovs-vsctl set port vpp${LAB}-${node}-${int} vlan_mode=native-untagged + done +done + +# Uplink is VLAN 10 +ovs-vsctl add port vpp${LAB}-0-0 tag 10 + +# Link vpp${LAB}-0 <-> vpp${LAB}-1 in VLAN 20 +ovs-vsctl add port vpp${LAB}-0-1 tag 20 +ovs-vsctl add port vpp${LAB}-1-0 tag 20 + +# Link vpp${LAB}-1 <-> vpp${LAB}-2 in VLAN 21 +ovs-vsctl add port vpp${LAB}-1-1 tag 21 +ovs-vsctl add port vpp${LAB}-2-0 tag 21 + +# Link vpp${LAB}-2 <-> vpp${LAB}-3 in VLAN 22 +ovs-vsctl add port vpp${LAB}-2-1 tag 22 +ovs-vsctl add port vpp${LAB}-3-0 tag 22 diff --git a/overlays/default/ovs-config.sh b/overlays/default/ovs-config.sh new file mode 120000 index 0000000..810b9d7 --- /dev/null +++ b/overlays/default/ovs-config.sh @@ -0,0 +1 @@ +../bird/ovs-config.sh \ No newline at end of file