summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStuart Mackie <wsmackie@juniper.net>2017-09-11 17:07:54 -0700
committerStuart Mackie <wsmackie@juniper.net>2017-09-11 17:07:54 -0700
commita41e8359b1e7e688217387ab91e7bcb6d39a4e8e (patch)
treeae4c03ee95896be0ba64f4c434cc68203bb29ce3
parenta4d2035eb10bff0017fff90ac3797db38074704a (diff)
OCL simple gateway logic
Change-Id: Id3d0afdd96d03f98028e1cbba71f0a470f1b7108 Signed-off-by: Stuart Mackie <wsmackie@juniper.net>
-rwxr-xr-xci/openstack.sh11
1 files changed, 11 insertions, 0 deletions
diff --git a/ci/openstack.sh b/ci/openstack.sh
index d449fb1b..bdfc1260 100755
--- a/ci/openstack.sh
+++ b/ci/openstack.sh
@@ -169,6 +169,9 @@ if [ "onos" == "$opnfvsdn" ]; then
launch_eth
neutron net-show ext-net > /dev/null 2>&1 || neutron net-create ext-net \
--router:external=True
+if [ "ocl" == "$opnfvsdn" ]; then
+ neutron net-show ext-net > /dev/null 2>&1 || neutron net-create ext-net
+
else
neutron net-show ext-net > /dev/null 2>&1 || neutron net-create ext-net \
--router:external=True \
@@ -180,6 +183,14 @@ neutron subnet-show ext-subnet > /dev/null 2>&1 || neutron subnet-create ext-net
--name ext-subnet --allocation-pool start=$EXTNET_FIP,end=$EXTNET_LIP \
--disable-dhcp --gateway $EXTNET_GW $EXTNET_NET
+# Ocl can push packets to the fabric network in order to reach a gateway if BGP/L3VPN hasn't been configured.
+if [ "ocl" == "$opnfvsdn" ]; then
+ echo "Creating simple gateway functions on ocl vRouters"
+ juju run --application nova-compute "ssh $UNIT sudo docker exec contrail-controller \
+ python /opt/contrail/utils/provision_vgw_interface.py\
+ --oper create --interface vgw1 --subnets $EXTNET_NET --routes 0.0.0.0/24 --vrf default-domain:admin:ext-net:ext-net"
+fi
+
domain_id=$(openstack domain show admin_domain -f value -c id)
project_id=$(openstack project show admin --domain $domain_id -f value -c id)