From 3bc3a8828c3ceefedd08e1767ae6e3bf2df9ac22 Mon Sep 17 00:00:00 2001 From: Harry Huang Date: Wed, 23 Aug 2017 15:05:02 +0800 Subject: Support multiple physnet mapping JIRA: COMPASS-559 1. support multiple mapping in provider_net_mappings of network.yml and create corresponding ovs bridges 2. support seperate config in sys_intf_mappings of network.yml 3. remove linux bridges in compute nodes for ovs port binding convenience 4. support openstack vlan tenant network 5. modify odl and odl_sfc roles to use configurable provider mapping 6. remove some hard coding Change-Id: Ib57484ce60d029f89c647fd5baf2c7af37c85d0b Signed-off-by: Harry Huang --- .../config-controller/templates/controller.j2 | 24 +++++++++++----------- 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'deploy/adapters/ansible/roles/config-controller/templates') diff --git a/deploy/adapters/ansible/roles/config-controller/templates/controller.j2 b/deploy/adapters/ansible/roles/config-controller/templates/controller.j2 index 2aeb9a04..4e444eca 100755 --- a/deploy/adapters/ansible/roles/config-controller/templates/controller.j2 +++ b/deploy/adapters/ansible/roles/config-controller/templates/controller.j2 @@ -10,35 +10,35 @@ auto eth0 iface eth0 inet manual # external interface -{% set intf_external = sys_intf_mappings["external"]["interface"] %} -{% if sys_intf_mappings["external"]["vlan_tag"] != "None" %} -{% set intf_external = intf_external + '.' + sys_intf_mappings["external"]["vlan_tag"]|string %} +{% set intf_external = contr_sys_mappings["external"]["interface"] %} +{% if contr_sys_mappings["external"]["vlan_tag"] | int %} +{% set intf_external = intf_external + '.' + contr_sys_mappings["external"]["vlan_tag"]|string %} {% endif %} auto {{ intf_external }} iface {{ intf_external }} inet manual -{% if sys_intf_mappings["external"]["vlan_tag"] != "None" %} +{% if contr_sys_mappings["external"]["vlan_tag"] | int %} vlan-raw-device {{ intf_external }} {% endif %} # tenant interface -{% set intf_tenant = sys_intf_mappings["tenant"]["interface"] %} -{% if sys_intf_mappings["tenant"]["interface"] != "None" %} -{% set intf_tenant = intf_tenant + '.' + sys_intf_mappings["tenant"]["vlan_tag"]|string %} +{% set intf_tenant = contr_sys_mappings["tenant"]["interface"] %} +{% if contr_sys_mappings["tenant"]["vlan_tag"] | int %} +{% set intf_tenant = intf_tenant + '.' + contr_sys_mappings["tenant"]["vlan_tag"]|string %} {% endif %} auto {{ intf_tenant }} iface {{ intf_tenant }} inet manual -{% if sys_intf_mappings["tenant"]["interface"] != "None" %} +{% if contr_sys_mappings["tenant"]["vlan_tag"] | int %} vlan-raw-device {{ intf_tenant }} {% endif %} # storage interface -{% set intf_storage = sys_intf_mappings["storage"]["interface"] %} -{% if sys_intf_mappings["storage"]["interface"] != "None" %} -{% set intf_storage = intf_storage + '.' + sys_intf_mappings["storage"]["vlan_tag"]|string %} +{% set intf_storage = contr_sys_mappings["storage"]["interface"] %} +{% if contr_sys_mappings["storage"]["vlan_tag"] | int %} +{% set intf_storage = intf_storage + '.' + contr_sys_mappings["storage"]["vlan_tag"]|string %} {% endif %} auto {{ intf_storage }} iface {{ intf_storage }} inet manual -{% if sys_intf_mappings["storage"]["interface"] != "None" %} +{% if contr_sys_mappings["storage"]["vlan_tag"] | int %} vlan-raw-device {{ intf_storage }} {% endif %} -- cgit 1.2.3-korg