Update relay entrypoint to wait bitcoin & blindbit

This commit is contained in:
omaroughriss 2025-09-13 01:05:22 +02:00
parent d481ba4b3e
commit 12a9837fb1

View File

@ -81,7 +81,14 @@ services:
- HOME=/home/bitcoin
- RUST_LOG=DEBUG
entrypoint: >
/bin/sh -lc "mkdir -p /home/bitcoin/.4nk/logs && exec /usr/local/bin/sdk_relay --config /home/bitcoin/.conf 2>&1 | tee -a /home/bitcoin/.4nk/logs/sdk_relay.log"
/bin/sh -lc '
echo "[relay] waiting for blindbit:8000...";
until [ "$(curl -s -o /dev/null -w "%{http_code}" http://blindbit:8000)" != "000" ]; do sleep 2; done
echo "[relay] waiting for bitcoind RPC 38332...";
until [ "$(curl -s -o /dev/null -w "%{http_code}" http://bitcoin:38332)" != "000" ]; do sleep 2; done
mkdir -p /home/bitcoin/.4nk/logs
exec /usr/local/bin/sdk_relay --config /home/bitcoin/.conf 2>&1 | tee -a /home/bitcoin/.4nk/logs/sdk_relay.log
'
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8090/health"]
interval: 30s