Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ The macOS builds are not notarized and the Windows installers are not Authentico
xattr -dr com.apple.quarantine "/Applications/Polar BLAKE2b.app"
```

The node images are built by the `Images` workflow from the Dockerfiles in [docker](docker), each pinned to a signed checksum file or, for LND, a source commit, as listed in [docker/README.md](docker/README.md).
The node images are built by the `Images` workflow from the Dockerfiles in [docker](docker), Bitcoin Knots is pinned to its signed checksum file, LND to a source commit, and Core Lightning builds on the `lightningd` image privkeyio/lightning publishes for each release; see [docker/README.md](docker/README.md).

## Reporting issues

Expand Down
4 changes: 2 additions & 2 deletions docker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,10 @@ Replace `<version>` with a tag of [paulscode/lightning-fork](https://github.com/

```sh
$ cd clightning
$ docker buildx build --platform linux/amd64,linux/arm64 --build-arg CLN_VERSION=<version> --build-arg CLN_SHA256SUMS=<sums> --build-arg BITCOIN_VERSION=<knots> --build-arg BITCOIN_SHA256SUMS=<knots-sums> -t ghcr.io/privkeyio/polar/clightning:<version> --push .
$ docker buildx build --platform linux/amd64,linux/arm64 --build-arg CLN_VERSION=<version> -t ghcr.io/privkeyio/polar/clightning:<version> --push .
```

Replace `<version>` with a release of [privkeyio/lightning](https://github.com/privkeyio/lightning) without the leading `v` (ex: `26.06.8-blake2b.6`) `<sums>` with the sha256 of its `SHA256SUMS-v<version>` once you have checked the `.asc` against the privkeyio key `A47D 99B6 DB0D 715D 40C5 9A20 23AE 8A8E A7E2 4E38` (for `26.06.8-blake2b.6`: `00de890637f5476a65de70bf52943d62173a5633b1c76b799bb2938b84bbd6bb`), and `<knots>` and `<knots-sums>` as for Bitcoin Knots above, whose `bitcoin-cli` it uses.
Replace `<version>` with a release of [privkeyio/lightning](https://github.com/privkeyio/lightning) without the leading `v` (ex: `26.06.8-blake2b.6`). The image builds on `ghcr.io/privkeyio/lightningd`, which privkeyio/lightning publishes for each release.

The images can also be built and pushed from master with the `Images` workflow in GitHub Actions, passing the same build args one per line.

Expand Down
35 changes: 8 additions & 27 deletions docker/clightning/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,41 +1,22 @@
FROM ubuntu:24.04
ARG CLN_VERSION
ARG CLN_IMAGE="ghcr.io/privkeyio/lightningd:v${CLN_VERSION}"

FROM ${CLN_IMAGE}

ARG CLN_VERSION
ARG CLN_SHA256SUMS
ARG BITCOIN_VERSION
ARG BITCOIN_SHA256SUMS

RUN userdel -r ubuntu \
&& apt-get update -y \
&& apt-get install -y curl gosu git xz-utils libsqlite3-0 libpq5 libsodium23 zlib1g \
# install gosu
RUN apt-get update -y \
&& apt-get install -y curl gosu git \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

RUN SYS_ARCH="$(dpkg --print-architecture)" \
&& curl -SLO https://github.com/privkeyio/lightning/releases/download/v${CLN_VERSION}/clightning-v${CLN_VERSION}-Ubuntu-24.04-${SYS_ARCH}.tar.xz \
&& curl -SLO https://github.com/privkeyio/lightning/releases/download/v${CLN_VERSION}/SHA256SUMS-v${CLN_VERSION} \
&& echo "${CLN_SHA256SUMS} SHA256SUMS-v${CLN_VERSION}" | sha256sum -c \
&& sha256sum --ignore-missing -c SHA256SUMS-v${CLN_VERSION} \
&& tar -xJf clightning-*.tar.xz -C / \
&& rm clightning-*.tar.xz SHA256SUMS-*

RUN SYS_ARCH="$(uname -m)" \
&& curl -SLO https://github.com/bitcoinknots/bitcoin/releases/download/v${BITCOIN_VERSION}/bitcoin-${BITCOIN_VERSION}-${SYS_ARCH}-linux-gnu.tar.gz \
&& curl -SLO https://github.com/bitcoinknots/bitcoin/releases/download/v${BITCOIN_VERSION}/SHA256SUMS \
&& echo "${BITCOIN_SHA256SUMS} SHA256SUMS" | sha256sum -c \
&& sha256sum --ignore-missing -c SHA256SUMS \
&& tar -xzf *.tar.gz \
&& install -m 755 bitcoin-${BITCOIN_VERSION}/bin/bitcoin-cli /usr/bin/bitcoin-cli \
&& rm -rf bitcoin-* SHA256SUMS

# download CLN bash completion file
RUN curl -SLO https://raw.githubusercontent.com/privkeyio/lightning/v${CLN_VERSION}/contrib/lightning-cli.bash-completion \
&& mkdir -p /etc/bash_completion.d \
&& mv lightning-cli.bash-completion /etc/bash_completion.d/lightning-cli

# install lightning-cli bash completion
RUN curl -SLO https://raw.githubusercontent.com/scop/bash-completion/master/bash_completion \
&& mkdir -p /usr/share/bash-completion \
&& mv bash_completion /usr/share/bash-completion/

COPY docker-entrypoint.sh /entrypoint.sh
Expand All @@ -49,4 +30,4 @@ EXPOSE 9735 9835 8080 10000

ENTRYPOINT ["/entrypoint.sh"]

CMD ["lightningd"]
CMD ["lightningd"]
Loading