diff options
author | waqas.ikram <waqas.ikram@est.tech> | 2019-08-14 14:27:41 +0000 |
---|---|---|
committer | Waqas Ikram <waqas.ikram@est.tech> | 2019-08-14 14:28:05 +0000 |
commit | 50e7ec9e942e0aaa75867ed854c926639514e5e7 (patch) | |
tree | 21465a80a69911967167d16b4196ff4577245a6d /plans/so/integration-etsi-testing/setup.sh | |
parent | 75c1171a3a0d0fbfe8a71b8b9fe308356f45c35d (diff) |
Minor update to wait-for-container script
Change-Id: I60fe89b1c16b961718e371f5bcf54b9d884160a7
Issue-ID: SO-2144
Signed-off-by: waqas.ikram <waqas.ikram@est.tech>
Diffstat (limited to 'plans/so/integration-etsi-testing/setup.sh')
-rwxr-xr-x | plans/so/integration-etsi-testing/setup.sh | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/plans/so/integration-etsi-testing/setup.sh b/plans/so/integration-etsi-testing/setup.sh index 6f0c0106..ee0058ef 100755 --- a/plans/so/integration-etsi-testing/setup.sh +++ b/plans/so/integration-etsi-testing/setup.sh @@ -47,6 +47,16 @@ echo "Running $SCRIPT_HOME/$SCRIPT_NAME ..." export $(egrep -v '^#' $ENV_FILE | xargs) +MANDATORY_VARIABLES_NAMES=( "NEXUS_DOCKER_REPO_MSO" "TAG" "TIME_OUT_DEFAULT_VALUE_SEC" "PROJECT_NAME" "DEFAULT_NETWORK_NAME") + +for var in "${MANDATORY_VARIABLES_NAMES[@]}" + do + if [ -z "${!var}" ]; then + echo "Missing mandatory attribute $var in $ENV_FILE" + exit 1 + fi +done + if [[ ! "$TEMP_DIR_PATH" || ! -d "$TEMP_DIR_PATH" ]]; then echo "Creating temporary directory $TEMP_DIR_PATH" mkdir $TEMP_DIR_PATH @@ -154,7 +164,7 @@ fi API_INFRA_CONTAINER_NAME="api-handler-infra" echo "Will execute $WAIT_FOR_CONTAINER_SCRIPT to wait for $API_INFRA_CONTAINER_NAME container to start up" -$WAIT_FOR_CONTAINER_SCRIPT -n "$API_INFRA_CONTAINER_NAME" -t "300" -p "${PROJECT_NAME}_default" +$WAIT_FOR_CONTAINER_SCRIPT -c "$API_INFRA_CONTAINER_NAME" -t "300" -n "$DEFAULT_NETWORK_NAME" if [ $? -ne 0 ]; then echo "ERROR: $WAIT_FOR_CONTAINER_SCRIPT failed" |