This docker-compose
template launches bitcoind
, lnd
and rtl
containers.
It is configured to run in regtest mode but can be modified to suit your needs.
bitcoind
is built from an Ubuntu repository and should not be used in production.lnd
will not sync to chain until Bitcoin regtest blocks are generated (see below).rtl
image is from the Docker Hub repository but you can change this to your needs.- Various ports and configs can be adjusted in the
.env
ordocker-compose.yml
files.
It may take several minutes if containers need to be built.
1.2.1) From the terminal in this folder:
$ docker-compose up -d bitcoind
$ bin/b-cli generate 101
$ docker-compose up -d lnd rtl
1.2.2) Check containers are up and running with:
$ docker-compose ps
1.2.3) Use the cli tools to get responses from the containers:
$ bin/ln-cli getinfo
$ bin/b-cli getblockchaininfo
1.2.4) View daemon logs as follows:
$ docker-compose logs bitcoind lnd rtl
Once the containers are running you can access the RTL UI at http://localhost:3000
- Default password is
password
. - Default host, port and password can be changed in
.env
.
When you are done you can destroy containers with:
$ docker-compose down -v
This is suitable when you already have a LND node running and configured.
RTL_VERSION=0.12.0
docker run --name rtl -d -it \
-e RTL_CONFIG_PATH=/RTLConfig \
-v /path/to/RTLConfig/dir:/RTLConfig \
-v /path/to/macaroon/dir:/path/as/specified/in/RTLConfig \
-v /path/to/database/dir:/RTL/database \
-p 3000:3000/tcp \
shahanafarooqui/rtl:${RTL_VERSION}
RTL_VERSION=0.12.0
docker build -t rtl:${RTL_VERSION} -f dockerfiles/Dockerfile .
Create an environment file with your required configurations. Sample .env:
RTL_CONFIG_PATH=/RTLConfig
MACAROON_PATH=/LNDMacaroon
LN_SERVER_URL=https://host.docker.internal:8080
RTL_VERSION=0.12.0
docker run -d -it \
-v /path/to/RTLConfig/dir:/RTLConfig \
-v /path/to/macaroon/dir:/LNDMacaroon \
-v /path/to/database/dir:/RTL/database \
--env-file=.env -p 3000:3000 rtl:${RTL_VERSION}
Once the container is running you can access the RTL UI at http://localhost:3000
@hashamadeus on Twitter