I want to use multiple nodes with the same remote bitcoind. E.g. my node on my desktop, my node on digital ocean, my node on Google cloud ...

I don't want to run everywhere a full bitcoind and pay for the disk space. I currently check the option to use btcpayserver (docker) on Google cloud as well. Again, it would need bitcoind.

Any hints welcome.

1 Answer 1


c-lightning internally calls bitcoin-cli and will pass a couple of commandline arguments to it. These arguments are all prefixed with --bitcoin-* and will match the ones that bitcoin-cli accepts.

So for your use-case you first need to make sure that bitcoin-cli is available on the machine that you will be running the c-lightning instances on. If it isn't you can simply use the Bitcoin PPA to install (but not run) bitcoind which will also install bitcoin-cli (assuming you're using a debian based OS):

sudo add-apt-repository ppa:bitcoin/bitcoin
sudo apt-get update

For a remote bitcoind you need to specify the following arguments:

  • --bitcoin-rpcconnect=<bitcoind-ip:port> this tells bitcoin-cli to connect to a remote bitcoind instance instead of trying localhost:8332 (make sure bitcoind is configured with -rpcallowip=<ip>, where <ip> is the machine you'll be running c-lightning on)
  • --bitcoin-rpcuser=<username> the username configured with bitcoind
  • --bitcoin-rpcpassword=<password> the password configured with bitcoind

In any case I'd suggest running bitcoin-cli --bitcoin-rpcconnect=<bitcoind-ip:port> --bitcoin-rpcuser=<username> --bitcoin-rpcpassword=<password> from the command line on the c-lightning machine to verify that bitcoind and bitcoin-cli are configured correctly.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.