Skip to content

Configuring a remote bitcoind node

CrypticaScriptura edited this page Feb 17, 2023 · 6 revisions

Notes for configuring a remote bitcoind node, available in version v8.5.0 and above.

Remote bitcoind server

This server runs bitcoind. The lamassu-server and lamassu-admin-server processes do not need to be running.

Edit bitcoin.conf to add these two lines:

rpcallowip=[admin server IP]
rpcbind=0.0.0.0

In this file, also comment out bind=0.0.0.0:8332 with #.

Assuming rpcport=8333 remains the same for the remote server configuration below.

Note the values for rpcuser and rpcpassword for the steps below.

Configure the firewall to allow connections on port 8333:

ufw allow 8333

Restart bitcoind with:

supervisorctl restart bitcoin

Admin server

This server runs lamassu-server and lamassu-admin-server, but does not run bitcoind.

Edit /etc/lamassu/.env to add the following values:

# Crypto node related variables

## Location info (can be local or remote)
BTC_NODE_LOCATION=remote
BTC_WALLET_LOCATION=remote

## Node connection info (remote node only)
BTC_NODE_HOST=[remote server IP]
BTC_NODE_PORT=8332

## Node connection info (remote wallet only)
BTC_NODE_RPC_HOST=[remote server IP]
BTC_NODE_RPC_PORT=8333
BTC_NODE_USER=[rpcuser value]
BTC_NODE_PASSWORD=[rpcpassword value]

Restart the Lamassu processes with:

supervisorctl restart lamassu-server lamassu-admin-server

The admin's Funding panel should now show a receiving address from the remote server's wallet. (You may confirm this by viewing the addresses listed with bitcoin-cli -conf=/mnt/blockchains/bitcoin/bitcoin.conf listreceivedbyaddress 0 true on the bitcoind server.)

Clone this wiki locally