From fa1bd4ad28d4e7aaec7c2cde29603118d840247a Mon Sep 17 00:00:00 2001 From: Alex Schultz Date: Thu, 1 Oct 2020 12:03:33 -0600 Subject: [PATCH] Standalone configure neutron bridge correctly This change updates the default bridge mapping from datacentre:br-ex to datacentre:br-ctlplane. We're doing this because in the standalone in CI, we configure a br-ex before running the standalone (via undercloud-setup) and want to attach our br-ctlplane to it. We then want to ensure that we use br-ctlplane for the neutron access to the external network to prevent weird routing issues when we have two bridges on the same subnet. Depends-On: https://review.opendev.org/#/c/757605/ Change-Id: I0e5aa3f58746dc0b92bd35ade7792f323b5647f7 Related-Bug: #1895822 --- roles/standalone-upgrade/README.md | 2 ++ roles/standalone-upgrade/defaults/main.yml | 2 ++ .../standalone-upgrade/templates/standalone_config.yaml.j2 | 6 ++++++ roles/standalone/README.md | 3 +++ roles/standalone/defaults/main.yml | 2 ++ roles/standalone/templates/standalone_config.yaml.j2 | 3 +++ 6 files changed, 18 insertions(+) diff --git a/roles/standalone-upgrade/README.md b/roles/standalone-upgrade/README.md index 9812df9e4..7977065d9 100644 --- a/roles/standalone-upgrade/README.md +++ b/roles/standalone-upgrade/README.md @@ -16,6 +16,8 @@ Role Variables - standalone_network_prefix: <'24'> -- The subnet size for the standalone deployment network - standalone_ip: <'192.168.24.1'> -- The IP address of the standalone upgrade - standalone_interface: <'br-ex'> -- The interface for the standalone upgrade +- standalone_neutron_bridge_mapping: <'datacentre:br-ctlplane,tenant:br-tenant'> -- The mapping for neutron network bridges +- standalone_neutron_physical_bridge: <'br-ctlplane'> -- Neutron physical bridge - standalone_container_prep_options: <''> -- additional parameters for the container prep command - standalone_container_prep_script: <'standalone-container-prep.sh.j2'> -- The script name use to perform container prep actions diff --git a/roles/standalone-upgrade/defaults/main.yml b/roles/standalone-upgrade/defaults/main.yml index a603f6d21..b1c3f88c3 100644 --- a/roles/standalone-upgrade/defaults/main.yml +++ b/roles/standalone-upgrade/defaults/main.yml @@ -5,6 +5,8 @@ standalone_network_prefix: 24 standalone_ip: 192.168.24.1 standalone_ha_control_virtual_ip: 192.168.24.3 standalone_interface: br-ex +standalone_neutron_bridge_mappings: "datacentre:br-ctlplane,tenant:br-tenant" +standalone_neutron_physical_bridge: br-ctlplane # container prep script standalone_container_prep_options: '' diff --git a/roles/standalone-upgrade/templates/standalone_config.yaml.j2 b/roles/standalone-upgrade/templates/standalone_config.yaml.j2 index dd27780b8..ef4858028 100644 --- a/roles/standalone-upgrade/templates/standalone_config.yaml.j2 +++ b/roles/standalone-upgrade/templates/standalone_config.yaml.j2 @@ -19,6 +19,12 @@ parameter_defaults: {{ standalone_network }}.0/{{ standalone_network_prefix }}: - {{ standalone_network }}.0/{{ standalone_network_prefix }} NeutronPublicInterface: {{ standalone_interface }} +{% if standalone_neutron_bridge_mappings is defined and standalone_neutron_bridge_mappings %} + NeutronBridgeMappings: {{ standalone_neutron_bridge_mappings }} +{% endif %} +{% if standalone_neutron_physical_bridge is defined and standalone_neutron_physical_bridge %} + NeutronPhysicalBridge: {{ standalone_neutron_physical_bridge }} +{% endif %} StandaloneCtlplaneLocalSubnet: ctlplane-subnet StandaloneCtlplaneSubnets: ctlplane-subnet: diff --git a/roles/standalone/README.md b/roles/standalone/README.md index 9ce77fca7..3a952b39a 100644 --- a/roles/standalone/README.md +++ b/roles/standalone/README.md @@ -17,6 +17,9 @@ Role Variables - standalone_network_prefix: <'24'> -- The subnet size for the standalone deployment network - standalone_ip: <'192.168.24.1'> -- The IP address of the standalone deployment - standalone_interface: <'br-ex'> -- The interface for the standalone deployment +- standalone_neutron_bridge_mapping: <'datacentre:br-ctlplane,tenant:br-tenant'> -- The mapping for neutron network bridges +- standalone_neutron_physical_bridge: <'br-ctlplane'> -- Neutron physical bridge + - standalone_hostname: <'standalone.localdomain'> -- FQDN to use for the system being deployed. Must be a fully qualified hostname with the domain. - standalone_container_prep_options: <''> -- additional parameters for the container prep command diff --git a/roles/standalone/defaults/main.yml b/roles/standalone/defaults/main.yml index 872d01859..cbd322cd4 100644 --- a/roles/standalone/defaults/main.yml +++ b/roles/standalone/defaults/main.yml @@ -5,6 +5,8 @@ standalone_network_prefix: 24 standalone_ip: 192.168.24.1 standalone_ha_control_virtual_ip: 192.168.24.3 standalone_interface: br-ex +standalone_neutron_bridge_mappings: "datacentre:br-ctlplane,tenant:br-tenant" +standalone_neutron_physical_bridge: br-ctlplane standalone_hostname: standalone.localdomain # container prep script diff --git a/roles/standalone/templates/standalone_config.yaml.j2 b/roles/standalone/templates/standalone_config.yaml.j2 index b9cbce9ab..3ae7ac59d 100644 --- a/roles/standalone/templates/standalone_config.yaml.j2 +++ b/roles/standalone/templates/standalone_config.yaml.j2 @@ -29,6 +29,9 @@ parameter_defaults: NeutronPublicInterface: {{ standalone_interface }} {% if standalone_neutron_bridge_mappings is defined and standalone_neutron_bridge_mappings %} NeutronBridgeMappings: {{ standalone_neutron_bridge_mappings }} +{% endif %} +{% if standalone_neutron_physical_bridge is defined and standalone_neutron_physical_bridge %} + NeutronPhysicalBridge: {{ standalone_neutron_physical_bridge }} {% endif %} StandaloneCtlplaneLocalSubnet: ctlplane-subnet StandaloneCtlplaneSubnets: