diff options
Diffstat (limited to 'test/csit/plans/aai/resources/setup.sh')
-rw-r--r-- | test/csit/plans/aai/resources/setup.sh | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/test/csit/plans/aai/resources/setup.sh b/test/csit/plans/aai/resources/setup.sh index a4c7648c0..bd5cb5214 100644 --- a/test/csit/plans/aai/resources/setup.sh +++ b/test/csit/plans/aai/resources/setup.sh @@ -26,6 +26,8 @@ DOCKER_IMAGE_VERSION=$(cat /opt/config/docker_version.txt) DOCKER_REGISTRY=${NEXUS_DOCKER_REPO} DOCKER_IMAGE_VERSION=1.2-STAGING-latest +export CURRENT_PWD=$(pwd); + function wait_for_container() { CONTAINER_NAME="$1"; @@ -71,10 +73,8 @@ ${DOCKER_COMPOSE_CMD} stop ${DOCKER_COMPOSE_CMD} rm -f -v # Start the hbase where the data will be stored -HBASE_CONTAINER_NAME=$(${DOCKER_COMPOSE_CMD} up -d aai.hbase.simpledemo.onap.org 2>&1 | grep 'Creating' | grep -v 'volume' | grep -v 'network' | awk '{ print $2; }' | head -1); -wait_for_container ${HBASE_CONTAINER_NAME} ' Started SelectChannelConnector@0.0.0.0:8085'; -wait_for_container ${HBASE_CONTAINER_NAME} ' Started SelectChannelConnector@0.0.0.0:8080'; -wait_for_container ${HBASE_CONTAINER_NAME} ' Started SelectChannelConnector@0.0.0.0:9095'; +CASSANDRA_CONTAINER_NAME=$(${DOCKER_COMPOSE_CMD} up -d aai.hbase.simpledemo.onap.org 2>&1 | grep 'Creating' | grep -v 'volume' | grep -v 'network' | awk '{ print $2; }' | head -1); +wait_for_container $CASSANDRA_CONTAINER_NAME 'Listening for thrift clients'; USER_EXISTS=$(check_if_user_exists aaiadmin); @@ -100,8 +100,10 @@ else export USER_ID=$(id -u aaiadmin); fi; +$DOCKER_COMPOSE_CMD run --rm aai-resources.api.simpledemo.onap.org createDBSchema.sh + RESOURCES_CONTAINER_NAME=$(${DOCKER_COMPOSE_CMD} up -d aai-resources.api.simpledemo.onap.org 2>&1 | grep 'Creating' | grep -v 'volume' | grep -v 'network' | awk '{ print $2; }' | head -1); -wait_for_container ${RESOURCES_CONTAINER_NAME} '0.0.0.0:8447'; +wait_for_container $RESOURCES_CONTAINER_NAME 'Resources Microservice Started'; docker logs ${RESOURCES_CONTAINER_NAME}; |