aboutsummaryrefslogtreecommitdiffstats
path: root/deployment/heat/onap-oom/scripts/deploy.sh
diff options
context:
space:
mode:
authorGary Wu <gary.i.wu@huawei.com>2018-09-07 22:03:48 -0700
committerGary Wu <gary.i.wu@huawei.com>2018-09-07 22:03:48 -0700
commit03e724f7d3b40b777da27ad2e29248391b4efd92 (patch)
tree34be9e293a8b4c51eb8d840ee8e7a6609faabb3a /deployment/heat/onap-oom/scripts/deploy.sh
parent8c66073fd7f6a1ba55e045c013cd1deadb293f7b (diff)
Add support for docker manifest parameter
Change-Id: Ie1d5aaa23c31f20455982155591c9cf34c02757b Issue-ID: INT-586 Signed-off-by: Gary Wu <gary.i.wu@huawei.com>
Diffstat (limited to 'deployment/heat/onap-oom/scripts/deploy.sh')
-rwxr-xr-xdeployment/heat/onap-oom/scripts/deploy.sh14
1 files changed, 11 insertions, 3 deletions
diff --git a/deployment/heat/onap-oom/scripts/deploy.sh b/deployment/heat/onap-oom/scripts/deploy.sh
index c3418faf4..e97c5a3f5 100755
--- a/deployment/heat/onap-oom/scripts/deploy.sh
+++ b/deployment/heat/onap-oom/scripts/deploy.sh
@@ -17,10 +17,11 @@ if [ -z "$WORKSPACE" ]; then
fi
usage() {
- echo "Usage: $0 [ -n <number of VMs {2-15}> ] [ -s <stack name> ][ -b <branch name> ][ -r ] <env>" 1>&2;
+ echo "Usage: $0 [ -n <number of VMs {2-15}> ][ -s <stack name> ][ -m <manifest> ][ -r ][ -q ] <env>" 1>&2;
echo "n: Set the number of VM's that will be installed. This number must be between 2 and 15" 1>&2;
echo "s: Set the name to be used for stack. This name will be used for naming of resources" 1>&2;
+ echo "m: The docker manifest to apply; must be either \"docker-manifest-staging.csv\" or \"docker-manifest.csv\"." 1>&2;
echo "r: Delete all resources relating to ONAP within enviroment." 1>&2;
echo "q: Quiet Delete of all ONAP resources." 1>&2;
@@ -28,7 +29,7 @@ usage() {
}
-while getopts ":n:s:rq" o; do
+while getopts ":n:s:m:rq" o; do
case "${o}" in
n)
if [[ ${OPTARG} =~ ^[0-9]+$ ]];then
@@ -48,6 +49,13 @@ while getopts ":n:s:rq" o; do
usage
fi
;;
+ m)
+ if [ -f $WORKSPACE/version-manifest/src/main/resources/${OPTARG} ]; then
+ docker_manifest=${OPTARG}
+ else
+ usage
+ fi
+ ;;
r)
echo "The following command will delete all information relating to onap within your enviroment"
read -p "Are you certain this is what you want? (type y to confirm):" answer
@@ -112,7 +120,7 @@ for n in $(seq 1 5); do
./scripts/gen-onap-oom-yaml.sh $vm_num > onap-oom.yaml~
fi
- if ! openstack stack create -t ./onap-oom.yaml~ -e $ENV_FILE~ $stack_name; then
+ if ! openstack stack create -t ./onap-oom.yaml~ -e $ENV_FILE~ $stack_name --parameter docker_manifest=$docker_manifest; then
break
fi