aboutsummaryrefslogtreecommitdiffstats
path: root/deploy/adapters/ansible/roles/config-controller/templates/controller.j2
diff options
context:
space:
mode:
authorHarry Huang <huangxiangyu5@huawei.com>2018-07-16 17:26:35 +0800
committerHarry Huang <huangxiangyu5@huawei.com>2018-07-16 17:26:35 +0800
commit7811e71b5c7eb4884be9d66b6c0d4cf30def87fb (patch)
tree235c989d83d4f0812dee247432c6263dc6f25cab /deploy/adapters/ansible/roles/config-controller/templates/controller.j2
parent568068caa189a8643cdd53de774259ab76297d43 (diff)
Add external veth pair
JIRA: COMPASS-604 Add veth pair and connect them to br-external. OpenDaylight can bind that veth instead of the external interface. Change-Id: I26f122bf8cab0943b7b056050de01381bab6d395 Signed-off-by: Harry Huang <huangxiangyu5@huawei.com>
Diffstat (limited to 'deploy/adapters/ansible/roles/config-controller/templates/controller.j2')
-rwxr-xr-xdeploy/adapters/ansible/roles/config-controller/templates/controller.j29
1 files changed, 9 insertions, 0 deletions
diff --git a/deploy/adapters/ansible/roles/config-controller/templates/controller.j2 b/deploy/adapters/ansible/roles/config-controller/templates/controller.j2
index ae654b47..8061ec1b 100755
--- a/deploy/adapters/ansible/roles/config-controller/templates/controller.j2
+++ b/deploy/adapters/ansible/roles/config-controller/templates/controller.j2
@@ -62,6 +62,15 @@ iface br-external inet static
address {{ ip_settings[inventory_hostname]["external"]["ip"] }}
netmask 255.255.255.0
gateway {{ ip_settings[inventory_hostname]["external"]["gw"] }}
+ offload-sg off
+ # Create veth pair, don't bomb if already exists
+ pre-up ip link add br-external-veth type veth peer name external-nic || true
+ # Set both ends UP
+ pre-up ip link set br-external-veth up
+ pre-up ip link set external-nic up
+ # Delete veth pair on DOWN
+ post-down ip link del br-external-veth || true
+ bridge_ports br-external-veth
# OpenStack Networking VXLAN (tunnel/overlay) bridge
#