aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2020-09-14 12:18:27 +0000
committerGerrit Code Review <review@openstack.org>2020-09-14 12:18:27 +0000
commitb49c86848dcd8d256e54d424d917a3b3b94d2d2c (patch)
treecc7085e9f34083a3d215f7d53345861614763f60 /tools
parent3d30624cc1396a9c11658e4780bf10889ac4c564 (diff)
parent7a3072e94c76aa2ca28c20c3a77e34a022948efd (diff)
downloadkolla-ansible-b49c86848dcd8d256e54d424d917a3b3b94d2d2c.tar.gz
kolla-ansible-b49c86848dcd8d256e54d424d917a3b3b94d2d2c.zip
Merge "[CI] Ensure network is set for Zun"
Diffstat (limited to 'tools')
-rwxr-xr-xtools/init-runonce19
1 files changed, 9 insertions, 10 deletions
diff --git a/tools/init-runonce b/tools/init-runonce
index 30c10c332..ac07c5a72 100755
--- a/tools/init-runonce
+++ b/tools/init-runonce
@@ -77,22 +77,21 @@ $KOLLA_OPENSTACK_COMMAND image create --disk-format qcow2 --container-format bar
--property os_type=${IMAGE_TYPE} --file ${IMAGE_PATH}/${IMAGE} ${IMAGE_NAME}
echo Configuring neutron.
-if [[ $ENABLE_EXT_NET -eq 1 ]]; then
- $KOLLA_OPENSTACK_COMMAND network create --external --provider-physical-network physnet1 \
- --provider-network-type flat public1
- $KOLLA_OPENSTACK_COMMAND subnet create --no-dhcp \
- --allocation-pool ${EXT_NET_RANGE} --network public1 \
- --subnet-range ${EXT_NET_CIDR} --gateway ${EXT_NET_GATEWAY} public1-subnet
-fi
+
+$KOLLA_OPENSTACK_COMMAND router create demo-router
$KOLLA_OPENSTACK_COMMAND network create demo-net
$KOLLA_OPENSTACK_COMMAND subnet create --subnet-range 10.0.0.0/24 --network demo-net \
--gateway 10.0.0.1 --dns-nameserver 8.8.8.8 demo-subnet
-
-$KOLLA_OPENSTACK_COMMAND router create demo-router
$KOLLA_OPENSTACK_COMMAND router add subnet demo-router demo-subnet
+
if [[ $ENABLE_EXT_NET -eq 1 ]]; then
- $KOLLA_OPENSTACK_COMMAND router set --external-gateway public1 demo-router
+ $KOLLA_OPENSTACK_COMMAND network create --external --provider-physical-network physnet1 \
+ --provider-network-type flat public1
+ $KOLLA_OPENSTACK_COMMAND subnet create --no-dhcp \
+ --allocation-pool ${EXT_NET_RANGE} --network public1 \
+ --subnet-range ${EXT_NET_CIDR} --gateway ${EXT_NET_GATEWAY} public1-subnet
+ $KOLLA_OPENSTACK_COMMAND router set --external-gateway public1 demo-router
fi
# Get admin user and tenant IDs