Skip to content

Commit

Permalink
feat: wait that restroom port is listening
Browse files Browse the repository at this point in the history
  • Loading branch information
albertolerda committed Jan 30, 2024
1 parent 053ca76 commit 54c4415
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion start-restroom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,10 @@ if [[ "$FILES" != "" ]]; then
fi

docker run --name $RESTROOM_CONTAINER_NAME --publish 3000:3000 $FILES_PARAMS $LOGGER_PARAMS -v "$CONTRACTS":"/app/contracts" --detach ghcr.io/dyne/restroom-mw:latest
sleep 7

IP=`docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $RESTROOM_CONTAINER_NAME`

while ! nc -z $IP 3000; do
echo "$IP is not up"
sleep 1
done

0 comments on commit 54c4415

Please sign in to comment.