-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Start deposit-monitor during upgrade-test.
This change is supported by moving the start code for the deposit-monitor to its own file.
- Loading branch information
Showing
3 changed files
with
46 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/bin/bash | ||
set -e | ||
|
||
source ./localnet/helper.sh | ||
|
||
# On some machines (e.g. MacOS), 172.17.0.1 is not accessible from inside the container, so we need to use host.docker.internal | ||
if [[ $CI == true ]]; then | ||
export CFDM_BROKER_API_URL='ws://172.17.0.1:10997' | ||
else | ||
export CFDM_BROKER_API_URL='ws://host.docker.internal:10997' | ||
fi | ||
$DOCKER_COMPOSE_CMD -f localnet/docker-compose.yml -p "chainflip-localnet" up $DEPOSIT_MONITOR_CONTAINER $additional_docker_compose_up_args -d >>$DEBUG_OUTPUT_DESTINATION 2>&1 | ||
while true; do | ||
echo "🩺 Checking deposit-monitor's health ..." | ||
REPLY=$(check_endpoint_health 'http://localhost:6060/health') | ||
starting=$(echo $REPLY | jq .starting) | ||
all_healthy=$(echo $REPLY | jq .all_processors) | ||
if test "$starting" == "false" && test "$all_healthy" == "true" ; then | ||
echo "💚 deposit-monitor is running!" | ||
break | ||
fi | ||
sleep 1 | ||
done |