You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
771 B
20 lines
771 B
#!/bin/bash
|
|
##########################
|
|
# Set host.docker.internal
|
|
# sudo /usr/bin/append-to-hosts "$(ip -4 route list match 0/0 | awk '{print $3 "\thost.docker.internal"}')"
|
|
echo Running modified mainnet script...
|
|
export BTC_RPC_PORT=${BITCOIN_RPC_PORT}
|
|
export ELECTRS_HOST=${ELECTRUM_IP}
|
|
export ELECTRS_PORT=${ELECTRUM_PORT}
|
|
# docker-compose.yml also passes the folllowing env vars:
|
|
# $BITCOIN_RPC_USER, $BITCOIN_RPC_PASS, $BITCOIN_RPC_AUTH,
|
|
# and $BITCOIN_IP
|
|
export PROXY_PORT=50002
|
|
# Replace strings in server.js
|
|
# bitcoind is not on localhost
|
|
sed -e 's/127.0.0.1/${BITCOIN_IP}/g' src/server.js
|
|
# Umbrel bitcoind uses RPC auth rather than cookie
|
|
sed -e 's/__cookie__\:${btcCookiePass}/${BITCOIN_RPC_USER}${BITCOIN_RPC_PASSWORD}/g' src/server.js
|
|
|
|
node src/server.js &
|
|
|
|
|