Skip to content

Commit c714c7e

Browse files
Jenkinsopenstack-gerrit
authored andcommitted
Merge "Use real Neutron network for L3 GW by default"
2 parents 61b3197 + 130a11f commit c714c7e

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

lib/neutron-legacy

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ TENANT_VLAN_RANGE=${TENANT_VLAN_RANGE:-}
203203
# agent, as described below.
204204
#
205205
# Example: ``PHYSICAL_NETWORK=default``
206-
PHYSICAL_NETWORK=${PHYSICAL_NETWORK:-}
206+
PHYSICAL_NETWORK=${PHYSICAL_NETWORK:-public}
207207

208208
# With the openvswitch agent, if using VLANs for tenant networks,
209209
# or if using flat or VLAN provider networks, set in ``localrc`` to
@@ -213,7 +213,7 @@ PHYSICAL_NETWORK=${PHYSICAL_NETWORK:-}
213213
# port for external connectivity.
214214
#
215215
# Example: ``OVS_PHYSICAL_BRIDGE=br-eth1``
216-
OVS_PHYSICAL_BRIDGE=${OVS_PHYSICAL_BRIDGE:-}
216+
OVS_PHYSICAL_BRIDGE=${OVS_PHYSICAL_BRIDGE:-br-ex}
217217

218218
# With the linuxbridge agent, if using VLANs for tenant networks,
219219
# or if using flat or VLAN provider networks, set in ``localrc`` to

lib/neutron_plugins/services/l3

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@ IPV6_PROVIDER_NETWORK_GATEWAY=${IPV6_PROVIDER_NETWORK_GATEWAY:-}
1717
PUBLIC_BRIDGE=${PUBLIC_BRIDGE:-br-ex}
1818
PUBLIC_BRIDGE_MTU=${PUBLIC_BRIDGE_MTU:-1500}
1919

20+
# If Q_ASSIGN_GATEWAY_TO_PUBLIC_BRIDGE=True, assign the gateway IP of the public
21+
# subnet to the public bridge interface even if Q_USE_PROVIDERNET_FOR_PUBLIC is
22+
# used.
23+
Q_ASSIGN_GATEWAY_TO_PUBLIC_BRIDGE=${Q_ASSIGN_GATEWAY_TO_PUBLIC_BRIDGE:-True}
24+
2025
# If Q_USE_PUBLIC_VETH=True, create and use a veth pair instead of
2126
# PUBLIC_BRIDGE. This is intended to be used with
2227
# Q_USE_PROVIDERNET_FOR_PUBLIC=True.
@@ -51,7 +56,7 @@ Q_L3_ROUTER_PER_TENANT=${Q_L3_ROUTER_PER_TENANT:-True}
5156
# Q_USE_PROVIDERNET_FOR_PUBLIC=True
5257
# PUBLIC_PHYSICAL_NETWORK=public
5358
# OVS_BRIDGE_MAPPINGS=public:br-ex
54-
Q_USE_PROVIDERNET_FOR_PUBLIC=${Q_USE_PROVIDERNET_FOR_PUBLIC:-False}
59+
Q_USE_PROVIDERNET_FOR_PUBLIC=${Q_USE_PROVIDERNET_FOR_PUBLIC:-True}
5560
PUBLIC_PHYSICAL_NETWORK=${PUBLIC_PHYSICAL_NETWORK:-public}
5661

5762
# Generate 40-bit IPv6 Global ID to comply with RFC 4193
@@ -305,7 +310,7 @@ function _neutron_configure_router_v4 {
305310
local cidr_len=${FLOATING_RANGE#*/}
306311
local testcmd="ip -o link | grep -q $ext_gw_interface"
307312
test_with_retry "$testcmd" "$ext_gw_interface creation failed"
308-
if [[ $(ip addr show dev $ext_gw_interface | grep -c $ext_gw_ip) == 0 && ( $Q_USE_PROVIDERNET_FOR_PUBLIC == "False" || $Q_USE_PUBLIC_VETH == "True" ) ]]; then
313+
if [[ $(ip addr show dev $ext_gw_interface | grep -c $ext_gw_ip) == 0 && ( $Q_USE_PROVIDERNET_FOR_PUBLIC == "False" || $Q_USE_PUBLIC_VETH == "True" || $Q_ASSIGN_GATEWAY_TO_PUBLIC_BRIDGE == "True" ) ]]; then
309314
sudo ip addr add $ext_gw_ip/$cidr_len dev $ext_gw_interface
310315
sudo ip link set $ext_gw_interface up
311316
fi

0 commit comments

Comments
 (0)