Skip to content

Commit

Permalink
HDDS-2045. Partially started compose cluster left running
Browse files Browse the repository at this point in the history
Closes #1358
  • Loading branch information
adoroszlai authored and elek committed Aug 29, 2019
1 parent 371c9eb commit c749f62
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions hadoop-ozone/dist/src/main/compose/testlib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,14 @@ start_docker_env(){
local -i datanode_count=${1:-3}

docker-compose -f "$COMPOSE_FILE" down
docker-compose -f "$COMPOSE_FILE" up -d --scale datanode="${datanode_count}"
wait_for_datanodes "$COMPOSE_FILE" "${datanode_count}"
sleep 10
docker-compose -f "$COMPOSE_FILE" up -d --scale datanode="${datanode_count}" \
&& wait_for_datanodes "$COMPOSE_FILE" "${datanode_count}" \
&& sleep 10

if [[ $? -gt 0 ]]; then
docker-compose -f "$COMPOSE_FILE" down
return 1
fi
}

## @description Execute robot tests in a specific container.
Expand Down

0 comments on commit c749f62

Please sign in to comment.