blob: 6bacaa5db3a684d848fa6e714f17d04547ad8a48 [file] [log] [blame]
#!/bin/bash
source ~/admin-openrc.sh
# Create nat-net network
neutron net-show nat-net 2>&1 > /dev/null
if [ "$?" -ne 0 ]
then
neutron net-create --provider:physical_network=nat --provider:network_type=flat --shared nat-net
fi
# Create nat-net subnet
neutron subnet-show nat-net 2>&1 > /dev/null
if [ "$?" -ne 0 ]
then
neutron subnet-create nat-net --name nat-net 172.16.0.0/16 --gateway=172.16.0.1 --enable-dhcp=false
fi
# Create nat-net network
neutron net-show ext-net 2>&1 > /dev/null
if [ "$?" -ne 0 ]
then
neutron net-create --provider:physical_network=ext --provider:network_type=flat --shared ext-net
fi