Compare commits
8 Commits
CLBOSS-v0.
...
CLN-v24.02
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
eff3b61785 | ||
|
|
22a3e0293a | ||
|
|
6ce34eecd7 | ||
|
|
ef1eec7f04 | ||
|
|
ee48f8406b | ||
|
|
7e5ac7c0e9 | ||
|
|
aee7a57c95 | ||
|
|
5002b0bb29 |
6
.env
6
.env
@@ -1,10 +1,10 @@
|
||||
# bitcoin version 26.0
|
||||
BITCOIN_VERSION=26.0
|
||||
BITCOIN_SHA256SUMS_HASH=63487c308a6655f939efd700bfca8e0285fa2f869283aaa7192bdd4b8799a747
|
||||
# core lightning version v24.02
|
||||
# core lightning version v24.02.2
|
||||
CORE_LIGHTNING_REPO=https://github.com/ElementsProject/lightning.git
|
||||
CORE_LIGHTNING_GIT_HASH=8418989f9bf3563a67ac91602500672b51628579
|
||||
# clboss
|
||||
CORE_LIGHTNING_GIT_HASH=a2a136fe3ebef1d028d1e20ebf1f987b8c05bbf8
|
||||
# clboss version v0.13.0
|
||||
CLBOSS_REPO=https://github.com/ZmnSCPxj/clboss.git
|
||||
CLBOSS_GIT_HASH=0673c50e7374ea8f5cb7e302f72b7978c6bd1794
|
||||
# cln plugins
|
||||
|
||||
41
README.md
41
README.md
@@ -138,21 +138,16 @@ __Note__: Even while using `testnet` running using the override is recommended a
|
||||
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
|
||||
docker compose -f docker-compose.yml -f $DOCKER_COMPOSE_OVERRIDE up --build
|
||||
```
|
||||
|
||||
Above command will run `bitcoind`, `lightningd` and `txood` services on a single node.
|
||||
|
||||
### Additional Regtest Commands
|
||||
## Interacting with Containers
|
||||
|
||||
We have to run these commands after bitcoind is up and running.
|
||||
We can use the `docker container exec <CONTAINER_NAME> <COMMAND>` command to interact with containers and interact with setup using command line tools like `bitcoin-cli`, `lightning-cli`, `vls-cli`, etc.
|
||||
|
||||
Create wallet and make it load automatically:
|
||||
```bash
|
||||
docker container exec bitcoind-regtest bitcoin-cli createwallet default
|
||||
docker container exec bitcoind-regtest bitcoin-cli unloadwallet default
|
||||
docker container exec bitcoind-regtest bitcoin-cli loadwallet default true
|
||||
```
|
||||
### Regtest Commands
|
||||
|
||||
Generate Address for node:
|
||||
```bash
|
||||
@@ -183,6 +178,34 @@ docker container exec lightningd-test lightning-cli --testnet clboss-status | le
|
||||
# Show node summary status
|
||||
docker container exec lightningd-test lightning-cli --testnet summary
|
||||
```
|
||||
|
||||
## Debugging Containers
|
||||
|
||||
Checking running status and health of containers
|
||||
```bash
|
||||
docker ps
|
||||
```
|
||||
|
||||
Getting logs from container
|
||||
```bash
|
||||
# CONTAINER_NAME=lightningd-test
|
||||
docker container logs $CONTAINER_NAME
|
||||
```
|
||||
|
||||
Restarting containers
|
||||
```bash
|
||||
cd vls-container
|
||||
docker compose --profile vls stop
|
||||
# to start testnet
|
||||
docker compose --profile vls up
|
||||
```
|
||||
|
||||
Delete containers
|
||||
```bash
|
||||
cd vls-container
|
||||
docker compose --profile vls down
|
||||
```
|
||||
|
||||
## Choosing Versions
|
||||
|
||||
The currently set default versions for services is as follows in the [.env](.env) file:
|
||||
|
||||
@@ -25,30 +25,27 @@ RUN mkdir $GNUPGHOME && set -ex \
|
||||
152812300785C96444D3334D17565732E08E5E41 \
|
||||
0AD83877C1F0CD1EE9BD660AD7CC770B81FD22A8 \
|
||||
590B7292695AFFA5B672CBB2E13FC145CD3F4304 \
|
||||
28F5900B1BB5D1A4B6B6D1A9ED357015286A333D \
|
||||
637DB1E23370F84AFF88CCE03152347D07DA627C \
|
||||
CFB16E21C950F67FA95E558F2EEB9F5CC09526C1 \
|
||||
F4FC70F07310028424EFC20A8E4256593F177720 \
|
||||
D1DBF2C4B96F2DEBF4C16654410108112E7EA81F \
|
||||
287AE4CA1187C68C08B49CB2D11BD4F33F1DB499 \
|
||||
F9A8737BF4FF5C89C903DF31DD78544CF91B1514 \
|
||||
9DEAE0DC7063249FB05474681E4AED62986CD25D \
|
||||
E463A93F5F3117EEDE6C7316BD02942421F4889F \
|
||||
9D3CC86A72F8494342EA5FD10A41BDC3F4FAFF1C \
|
||||
4DAF18FE948E7A965B30F9457E296D555E7F63A7 \
|
||||
3EB0DEE6004A13BE5A0CC758BF2978B068054311 \
|
||||
ED9BDF7AD6A55E232E84524257FF9BDBCC301009 \
|
||||
28E72909F1717FE9607754F8A7BEB2621678D37D \
|
||||
74E2DEF5D77260B98BC19438099BAD163C70FBFA \
|
||||
; do \
|
||||
gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$key" || \
|
||||
gpg --batch --keyserver keys.openpgp.org --recv-keys "$key" || \
|
||||
gpg --batch --keyserver pgp.mit.edu --recv-keys "$key" || \
|
||||
gpg --batch --keyserver keyserver.pgp.com --recv-keys "$key" || \
|
||||
gpg --batch --keyserver ha.pool.sks-keyservers.net --recv-keys "$key" || \
|
||||
gpg --batch --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys "$key" ; \
|
||||
done && \
|
||||
wget -O- https://raw.githubusercontent.com/Kvaciral/kvaciral/main/kvaciral.asc | gpg --import
|
||||
|
||||
done
|
||||
RUN gpg --keyserver hkps://keys.openpgp.org --refresh-keys
|
||||
RUN gpg -kv
|
||||
|
||||
COPY verify.sh verify.sh
|
||||
|
||||
ARG BITCOIN_VERSION
|
||||
ARG BITCOIN_PREFIX=/opt/bitcoin-${BITCOIN_VERSION}
|
||||
ARG BITCOIN_SHA256SUMS_HASH
|
||||
@@ -56,16 +53,16 @@ RUN echo "Building bitcoin core version $BITCOIN_VERSION"
|
||||
RUN wget https://bitcoincore.org/bin/bitcoin-core-${BITCOIN_VERSION}/SHA256SUMS && \
|
||||
wget https://bitcoincore.org/bin/bitcoin-core-${BITCOIN_VERSION}/SHA256SUMS.asc && \
|
||||
wget https://bitcoincore.org/bin/bitcoin-core-${BITCOIN_VERSION}/bitcoin-${BITCOIN_VERSION}.tar.gz && \
|
||||
gpg --batch --verify SHA256SUMS.asc SHA256SUMS && \
|
||||
./verify.sh && \
|
||||
echo "${BITCOIN_SHA256SUMS_HASH} SHA256SUMS" | sha256sum -c - && \
|
||||
grep " bitcoin-${BITCOIN_VERSION}.tar.gz\$" SHA256SUMS | sha256sum -c - && \
|
||||
tar -xzf *.tar.gz
|
||||
|
||||
WORKDIR /bitcoin-${BITCOIN_VERSION}
|
||||
|
||||
RUN sed -i '/AC_PREREQ/a\AR_FLAGS=cr' src/univalue/configure.ac && \
|
||||
RUN sed -i '/AC_PREREQ/a\AR_FLAGS=cr' configure.ac && \
|
||||
sed -i '/AX_PROG_CC_FOR_BUILD/a\AR_FLAGS=cr' src/secp256k1/configure.ac && \
|
||||
sed -i s:sys/fcntl.h:fcntl.h: src/compat.h && \
|
||||
sed -i s:sys/fcntl.h:fcntl.h: src/compat/compat.h && \
|
||||
./autogen.sh && \
|
||||
./configure LDFLAGS=-L`ls -d /opt/db*`/lib/ CPPFLAGS=-I`ls -d /opt/db*`/include/ \
|
||||
--prefix=${BITCOIN_PREFIX} \
|
||||
|
||||
12
bitcoind/verify.sh
Executable file
12
bitcoind/verify.sh
Executable file
@@ -0,0 +1,12 @@
|
||||
#!/bin/sh
|
||||
|
||||
# verify SHA256SUMS
|
||||
gpg --batch --verify SHA256SUMS.asc SHA256SUMS
|
||||
ret_val=$?
|
||||
|
||||
# allow 2 as well in case of untrusted keys
|
||||
if [ $ret_val -eq 0 ] || [ $ret_val -eq 2 ]; then
|
||||
exit 0
|
||||
else
|
||||
exit $ret_val
|
||||
fi
|
||||
@@ -20,6 +20,7 @@ RUN apk update && \
|
||||
net-tools \
|
||||
postgresql-dev \
|
||||
py3-mako \
|
||||
py3-pip \
|
||||
python3 \
|
||||
python3-dev \
|
||||
sqlite-dev \
|
||||
@@ -27,13 +28,14 @@ RUN apk update && \
|
||||
zlib-dev \
|
||||
zlib-static
|
||||
|
||||
RUN pip3 install grpcio-tools
|
||||
|
||||
ARG CORE_LIGHTNING_GIT_HASH \
|
||||
CORE_LIGHTNING_REPO
|
||||
RUN git clone --recursive $CORE_LIGHTNING_REPO core-lightning
|
||||
RUN cd core-lightning && \
|
||||
git checkout $CORE_LIGHTNING_GIT_HASH && \
|
||||
./configure --enable-static --prefix=/usr && \
|
||||
make -j $(nproc) && \
|
||||
make -j $(nproc) install && \
|
||||
make clean
|
||||
|
||||
@@ -128,7 +130,7 @@ COPY --from=builder /usr/libexec/c-lightning /usr/libexec/c-lightning
|
||||
COPY --from=builder /usr/share/man/man8 /usr/share/man/man8
|
||||
COPY --from=builder /usr/share/doc/c-lightning /usr/share/doc/c-lightning
|
||||
COPY --from=clboss_builder /usr/bin/clboss /usr/bin/clboss
|
||||
COPY --from=builder /build/plugins/summary /usr/local/src/plugins/summary
|
||||
COPY --from=builder /build/plugins/archived/summary /usr/local/src/plugins/summary
|
||||
COPY --from=vls_builder /usr/local/bin/remote_hsmd_socket /usr/libexec/c-lightning/remote_hsmd_socket
|
||||
|
||||
RUN addgroup -S lightning && adduser -S lightning -G lightning && \
|
||||
|
||||
@@ -5,6 +5,7 @@ cp -u /testnet-config ${LIGHTNINGD_DATA}/testnet-config
|
||||
cp -u /regtest-config ${LIGHTNINGD_DATA}/regtest-config
|
||||
|
||||
export GREENLIGHT_VERSION=$(lightningd --version)
|
||||
export VLS_CLN_VERSION=$(lightningd --version)
|
||||
|
||||
if [ $(echo "$1" | cut -c1) = "-" ]; then
|
||||
echo "$0: assuming arguments for lightningd"
|
||||
|
||||
Reference in New Issue
Block a user