Merge "Fix test files created during execution"
authorJorge Hernandez <jorge.hernandez-herrero@att.com>
Wed, 1 May 2019 13:43:35 +0000 (13:43 +0000)
committerGerrit Code Review <gerrit@onap.org>
Wed, 1 May 2019 13:43:35 +0000 (13:43 +0000)
packages/base/src/files/install/mysql/data/190202_upgrade_script.sql
packages/docker/src/main/docker/Dockerfile
packages/docker/src/main/docker/wait-for-port.sh

index e610bc9..c36a6f4 100644 (file)
@@ -43,3 +43,4 @@ VALUES ('GocVNFType', 'getDictionary/get_GocVnfTypeDataByName', 'gocVnfTypeDicti
 ('ServerScope','getDictionary/get_ServerScopeDataByName','gocServerScopeDictionaryDatas'),
 ('TraversalData', 'getDictionary/get_TraversalDataByName', 'gocTraversalDictionaryDatas'); 
 
+INSERT INTO `onap_sdk`.`fn_user_role` (USER_ID, ROLE_ID, APP_ID) VALUES (1, 16, 1);
index 69639cc..6b04b63 100644 (file)
@@ -2,8 +2,10 @@ FROM onap/policy-common-alpine:1.4.0
 
 LABEL maintainer="Policy Team"
 
+ARG BUILD_VERSION_ENGINE=${BUILD_VERSION_ENGINE}
 ARG POLICY_LOGS=/var/log/onap
 
+ENV BUILD_VERSION_ENGINE ${BUILD_VERSION_ENGINE}
 ENV POLICY_LOGS ${POLICY_LOGS}
 
 RUN apk add --no-cache mariadb-client
index befebf2..15c6eb8 100644 (file)
@@ -25,14 +25,17 @@ if [[ $# -ne 2 ]]; then
        exit 1
 fi
 
-host=$1
-port=$2
+export host=$1
+export port=$2
 
 echo "Waiting for $host port $port open"
-until nc -vz $host $port 2> /dev/null; do
-       sleep 1
-done
+timeout 120 bash -c 'until nc -vz "$host" "$port"; do echo -n "."; sleep 1; done'
+rc=$?
 
-echo "$host port $port is open"
+if [[ $rc != 0 ]]; then
+       echo "$host port $port cannot be reached"
+       exit $rc
+fi
 
+echo "$host port $port is open"
 exit 0