Changeset View
Changeset View
Standalone View
Standalone View
contrib/seeds/test-seeds.sh
Show First 20 Lines • Show All 67 Lines • ▼ Show 20 Lines | |||||
>&2 echo "Spinning up bitcoind..." | >&2 echo "Spinning up bitcoind..." | ||||
${BITCOIND} || { | ${BITCOIND} || { | ||||
echo "Error starting bitcoind. Stopping script." | echo "Error starting bitcoind. Stopping script." | ||||
exit 12 | exit 12 | ||||
} | } | ||||
cleanup() { | cleanup() { | ||||
# Cleanup background processes spawned by this script. | # Cleanup background processes spawned by this script. | ||||
>&2 echo "Cleaning up bitcoin daemon..." | >&2 echo "Cleaning up bitcoin daemon..." | ||||
${BITCOIN_CLI} stop | >&2 ${BITCOIN_CLI} stop | ||||
rm -rf "${TEMP_DATADIR}" | rm -rf "${TEMP_DATADIR}" | ||||
} | } | ||||
trap "cleanup" EXIT | trap "cleanup" EXIT | ||||
# Short sleep to make sure the RPC server is available | # Short sleep to make sure the RPC server is available | ||||
sleep 0.1 | sleep 0.1 | ||||
# Wait until bitcoind is fully spun up | # Wait until bitcoind is fully spun up | ||||
WARMUP_TIMEOUT=60 | WARMUP_TIMEOUT=60 | ||||
▲ Show 20 Lines • Show All 48 Lines • Show Last 20 Lines |