X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;ds=sidebyside;f=kubernetes%2Frobot%2Fdemo-k8s.sh;h=c4124c2ad40fcea0883ebae86498c62b926e2a3c;hb=1af5fbeb9f212a544a3230f0ad1a7a7bfd990338;hp=de3362740ece420bc08267521448b527c081e782;hpb=c48356040529d981eb1f4bb78e68e0687a68afb4;p=oom.git diff --git a/kubernetes/robot/demo-k8s.sh b/kubernetes/robot/demo-k8s.sh index de3362740e..c4124c2ad4 100755 --- a/kubernetes/robot/demo-k8s.sh +++ b/kubernetes/robot/demo-k8s.sh @@ -1,4 +1,18 @@ -#!/bin/bash -x +# Copyright © 2018 Amdocs, Bell Canada +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +#!/bin/bash # # Execute tags built to support the hands on demo, @@ -69,7 +83,7 @@ do VARIABLES="$VARIABLES -v WEB_PASSWORD:$WEB_PASSWORD" shift if [ $# -eq 2 ];then - VARIABLES="$VARIABLES -v HOSTS_PREFIX:$2" + VARIABLES="$VARIABLES -v HOSTS_PREFIX:$1" fi shift ;; @@ -85,7 +99,7 @@ do TAG="InitDistribution" shift if [ $# -eq 1 ];then - VARIABLES="$VARIABLES -v DEMO_PREFIX:$2" + VARIABLES="$VARIABLES -v DEMO_PREFIX:$1" fi shift ;; @@ -93,24 +107,24 @@ do TAG="PreloadDemo" shift if [ $# -ne 2 ];then - echo "Usage: demo.sh preload " + echo "Usage: demo.sh preload " exit fi - VARIABLES="$VARIABLES -v VNF_NAME:$2" + VARIABLES="$VARIABLES -v VNF_NAME:$1" shift - VARIABLES="$VARIABLES -v MODULE_NAME:$2" + VARIABLES="$VARIABLES -v MODULE_NAME:$1" shift ;; appc) - TAG="APPCMountPointDemo" - shift - if [ $# -ne 1 ];then - echo "Usage: demo.sh appc " - exit - fi - VARIABLES="$VARIABLES -v MODULE_NAME:$2" - shift - ;; + TAG="APPCMountPointDemo" + shift + if [ $# -ne 1 ];then + echo "Usage: demo.sh appc " + exit + fi + VARIABLES="$VARIABLES -v MODULE_NAME:$1" + shift + ;; instantiateVFW) TAG="instantiateVFW" VARIABLES="$VARIABLES -v GLOBAL_BUILD_NUMBER:$$" @@ -120,10 +134,10 @@ do TAG="deleteVNF" shift if [ $# -ne 1 ];then - echo "Usage: demo.sh deleteVNF " + echo "Usage: demo.sh deleteVNF " exit fi - VARFILE=$2.py + VARFILE=$1.py if [ -e /opt/eteshare/${VARFILE} ]; then VARIABLES="$VARIABLES -V /share/${VARFILE}" else @@ -136,14 +150,14 @@ do TAG="heatbridge" shift if [ $# -ne 3 ];then - echo "Usage: demo.sh heatbridge " + echo "Usage: demo.sh heatbridge " exit fi - VARIABLES="$VARIABLES -v HB_STACK:$2" + VARIABLES="$VARIABLES -v HB_STACK:$1" shift - VARIABLES="$VARIABLES -v HB_SERVICE_INSTANCE_ID:$2" + VARIABLES="$VARIABLES -v HB_SERVICE_INSTANCE_ID:$1" shift - VARIABLES="$VARIABLES -v HB_SERVICE:$2" + VARIABLES="$VARIABLES -v HB_SERVICE:$1" shift ;; *) @@ -152,6 +166,8 @@ do esac done +set -x + ETEHOME=/var/opt/OpenECOMP_ETE VARIABLEFILES="-V /share/config/vm_properties.py -V /share/config/integration_robot_properties.py -V /share/config/integration_preload_parameters.py" POD=$(kubectl --namespace $NAMESPACE get pods | sed 's/ .*//'| grep robot)