blob: efa35fcf5f77ae26fbb333cd5303a57accef5abc [file] [log] [blame]
Andy Bavier8d51c6c2015-04-01 11:40:22 -04001#!/bin/sh
2
3source ~/admin_openrc.sh
4
5# Create nat-net network
6neutron net-show nat-net 2&>1 > /dev/null
7if [ "$?" -ne 0 ]
8then
9 neutron net-create --provider:physical_network=nat --provider:network_type=flat --shared nat-net
10fi
11
12# Create nat-net subnet
13neutron subnet-show nat-net 2&>1 > /dev/null
14if [ "$?" -ne 0 ]
15then
16 neutron subnet-create nat-net --name nat-net 172.16.0.0/16 --gateway=172.16.0.1 --enable-dhcp=false
17fi
18
19# Create nat-net network
20neutron net-show ext-net 2&>1 > /dev/null
21if [ "$?" -ne 0 ]
22then
23 neutron net-create --provider:physical_network=ext --provider:network_type=flat --shared ext-net
24fi
25
26