From cdd28817e235403a9ae8c8de9f147dd7d6d8a0bf Mon Sep 17 00:00:00 2001 From: Lakshya Singh Date: Sun, 19 Nov 2023 01:24:27 +0530 Subject: [PATCH] compose: enable profile vls for vls service - allow running all services without vls on same node Signed-off-by: Lakshya Singh --- README.md | 14 ++++++++++++-- docker-compose.yml | 2 ++ 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 404ddcc..7bea844 100644 --- a/README.md +++ b/README.md @@ -112,7 +112,7 @@ docker volume create vls_data ### Docker Compose Run ```bash -docker compose up --build +docker compose --profile vls up --build ``` ### Selecting Bitcoin Chains @@ -125,11 +125,21 @@ To use override we have to pass it down both the config using `-f` flag: ```bash export DOCKER_COMPOSE_OVERRIDE=docker-compose.testnet.yml export COMPOSE_PROJECT_NAME=testnet -docker compose -f docker-compose.yml -f $DOCKER_COMPOSE_OVERRIDE up --build +docker compose --profile vls -f docker-compose.yml -f $DOCKER_COMPOSE_OVERRIDE up --build ``` __Note__: Even while using `testnet` running using the override is recommended as that will expose the `P2P` port for `bitcoind` and `P2P` port for `lightningd` on the host. +### Single Node without VLS + +To run a single node without `vls` service we can use the same `docker-compose.yml` file in the main directory by just removing the `profile` flag `vls` from all commands. + +```bash +docker compose up --build +``` + +Above command will run `bitcoind`, `lightningd` and `txood` services on a single node. + ### Additional Regtest Commands We have to run these commands after bitcoind is up and running. diff --git a/docker-compose.yml b/docker-compose.yml index 7c2242b..ee3182a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -66,6 +66,8 @@ services: context: ./vlsd image: vlsd container_name: vlsd-test + profiles: + - vls command: - --log-level=info - --connect=http://core-lightning:7701