Remove need for custom RPC variables for BTC Pay

This commit is contained in:
Taylor Helsper 2022-05-17 23:15:18 -05:00
parent cdb6a94996
commit 656ec4d75d
2 changed files with 6 additions and 6 deletions

View File

@ -4,8 +4,8 @@ source /usr/share/mynode/mynode_config.sh
set -x
# Update Bitcoin RPC Password
# Update Bitcoin RPC Credentials
BTCRPCPW=$(cat /mnt/hdd/mynode/settings/.btcrpcpw)
if [ -f /mnt/hdd/mynode/btcpayserver/.env ]; then
sed -i "s/REMOTE_BTC_RPC_PASSWORD=.*/REMOTE_BTC_RPC_PASSWORD=$BTCRPCPW/g" /mnt/hdd/mynode/btcpayserver/.env
fi
NBXPLORER_VARIABLES_FILE=/mnt/hdd/mynode/btcpayserver/btcpayserver-docker/Generated/nbxplorer-variables.env
echo "NBXPLORER_BTCRPCUSER=mynode" > $NBXPLORER_VARIABLES_FILE
echo "NBXPLORER_BTCRPCPASSWORD=$BTCRPCPW" >> $NBXPLORER_VARIABLES_FILE

View File

@ -6,11 +6,11 @@ services:
BTCPAY_CHAINS: "btc"
BTCPAY_BTCEXPLORERURL: http://nbxplorer:32838/
nbxplorer:
env_file:
- nbxplorer-variables.env
environment:
NBXPLORER_CHAINS: "btc"
NBXPLORER_BTCRPCURL: http://host.docker.internal:8332/
NBXPLORER_BTCRPCUSER: "${REMOTE_BTC_RPC_USERNAME}"
NBXPLORER_BTCRPCPASSWORD: "${REMOTE_BTC_RPC_PASSWORD}"
NBXPLORER_BTCNODEENDPOINT: host.docker.internal:8333
volumes:
- "/mnt/hdd/mynode/bitcoin:/root/.bitcoin"