summaryrefslogtreecommitdiffstats
path: root/ci/deploy.sh
diff options
context:
space:
mode:
authorNarinder Gupta <narinder.gupta@canoncial.com>2015-09-22 23:14:00 -0500
committerNarinder Gupta <narinder.gupta@canoncial.com>2015-09-22 23:16:09 -0500
commit62632e5960810566091186f2ec90bf10d9f2d4af (patch)
treef544af1aec71107b081a645c7fa30958b8851f4e /ci/deploy.sh
parente6b6f4362ea2a5bd53ac32118496b61854a0a736 (diff)
Adding the maas deployment script. This will deploy the maas in a
VM. Also add a bootdtrap node. deploy.yaml will contain the config file to deploy the openstack release. deployment.yaml will be lab specific where it will install the maas in a particular lab. Change-Id: I9d19e06eeac55666fc38a8db22fe8ba0bda7a764
Diffstat (limited to 'ci/deploy.sh')
-rwxr-xr-xci/deploy.sh38
1 files changed, 31 insertions, 7 deletions
diff --git a/ci/deploy.sh b/ci/deploy.sh
index 7f39a935..f33ad4be 100755
--- a/ci/deploy.sh
+++ b/ci/deploy.sh
@@ -1,7 +1,6 @@
#!/bin/bash
set -ex
-./00-bootstrap.sh
#need to put mutiple cases here where decide this bundle to deploy by default use the odl bundle.
# Below parameters are the default and we can according the release
@@ -10,13 +9,23 @@ opnfvsdn=odl
opnfvtype=nonha
openstack=kilo
opnfvlab=intelpod5
+opnfvrel=b
+
+read_config() {
+ opnfvrel=`grep release: deploy.yaml | cut -d ":" -f2`
+ openstack=`grep openstack: deploy.yaml | cut -d ":" -f2`
+ opnfvtype=`grep type: deploy.yaml | cut -d ":" -f2`
+ opnfvlab=`grep lab: deploy.yaml | cut -d ":" -f2`
+ opnfvsdn=`grep sdn: deploy.yaml | cut -d ":" -f2`
+}
usage() { echo "Usage: $0 [-s <odl|opencontrail>]
[-t <nonha|ha|tip>]
[-o <juno|kilo|liberty>]
- [-l <intelpod5>]" 1>&2 exit 1;}
+ [-l <intelpod5>]
+ [-r <a|b>]" 1>&2 exit 1; }
-while getopts ":s:t:o:l:h:" opt; do
+while getopts ":s:t:o:l:h:r:" opt; do
case "${opt}" in
s)
opnfvsdn=${OPTARG}
@@ -30,6 +39,9 @@ while getopts ":s:t:o:l:h:" opt; do
l)
opnfvlab=${OPTARG}
;;
+ r)
+ opnfvrel=${OPTARG}
+ ;;
h)
usage
;;
@@ -38,9 +50,21 @@ while getopts ":s:t:o:l:h:" opt; do
esac
done
-#copy the script which needs to get deployed as part of ofnfv release
-cp ./$opnfvsdn/01-deploybundle.sh ./01-deploybundle.sh
+deploy() {
+ #copy the script which needs to get deployed as part of ofnfv release
+ echo "deploying now"
+ cp ./$opnfvsdn/01-deploybundle.sh ./01-deploybundle.sh
+ ./00-bootstrap.sh
+
+ #case default:
+ ./01-deploybundle.sh $opnfvtype $openstack $opnfvlab
+}
-#case default:
-./01-deploybundle.sh $opnfvtype $openstack $opnfvlab
+if [ "$#" -eq 0 ]; then
+ echo "This installtion will use deploy.yaml"
+ read_config
+fi
+echo "deploying started"
+deploy
+echo "deploying finished"