echo " demo.sh <namespace> appc <module_name>"
echo " - provide APPC with vFW module mount point for closed loop"
echo " "
- echo " demo.sh <namespace> init_robot"
+ echo " demo.sh <namespace> init_robot [ <etc_hosts_prefix> ]"
echo " - Initialize robot after all ONAP VMs have started"
echo " "
echo " demo.sh <namespace> instantiateVFW"
}
# Set the defaults
-if [ $# -le 1 ];then
+if [ $# -le 2 ];then
usage
exit
fi
##
## if more than 1 tag is supplied, the must be provided with -i or -e
##
-while [ $# -gt 0 ]
+while [ $# -gt 1 ]
do
- key="$1"
+ key="$2"
case $key in
init_robot)
fi
VARIABLES="$VARIABLES -v WEB_PASSWORD:$WEB_PASSWORD"
shift
+ if [ $# -eq 2 ];then
+ VARIABLES="$VARIABLES -v HOSTS_PREFIX:$2"
+ fi
+ shift
;;
init)
TAG="InitDemo"
TAG="InitDistribution"
shift
if [ $# -eq 1 ];then
- VARIABLES="$VARIABLES -v DEMO_PREFIX:$1"
+ VARIABLES="$VARIABLES -v DEMO_PREFIX:$2"
fi
shift
;;
echo "Usage: demo.sh preload <vnf_name> <module_name>"
exit
fi
- VARIABLES="$VARIABLES -v VNF_NAME:$1"
+ VARIABLES="$VARIABLES -v VNF_NAME:$2"
shift
- VARIABLES="$VARIABLES -v MODULE_NAME:$1"
+ VARIABLES="$VARIABLES -v MODULE_NAME:$2"
shift
;;
appc)
echo "Usage: demo.sh appc <module_name>"
exit
fi
- VARIABLES="$VARIABLES -v MODULE_NAME:$1"
+ VARIABLES="$VARIABLES -v MODULE_NAME:$2"
shift
;;
instantiateVFW)
echo "Usage: demo.sh deleteVNF <module_name from instantiateVFW>"
exit
fi
- VARFILE=$1.py
+ VARFILE=$2.py
if [ -e /opt/eteshare/${VARFILE} ]; then
VARIABLES="$VARIABLES -V /share/${VARFILE}"
else
echo "Cache file ${VARFILE} is not found"
exit
fi
- shift
+ shift
;;
heatbridge)
TAG="heatbridge"
echo "Usage: demo.sh heatbridge <stack_name> <service_instance_id> <service>"
exit
fi
- VARIABLES="$VARIABLES -v HB_STACK:$1"
+ VARIABLES="$VARIABLES -v HB_STACK:$2"
shift
- VARIABLES="$VARIABLES -v HB_SERVICE_INSTANCE_ID:$1"
+ VARIABLES="$VARIABLES -v HB_SERVICE_INSTANCE_ID:$2"
shift
- VARIABLES="$VARIABLES -v HB_SERVICE:$1"
+ VARIABLES="$VARIABLES -v HB_SERVICE:$2"
shift
;;
*)