2023-11-13 04:55:15 +00:00
|
|
|
FROM alpine:latest as bitcoin
|
|
|
|
|
2023-12-12 13:20:44 +00:00
|
|
|
ENV BITCOIN_VERSION=26.0
|
2023-11-13 04:55:15 +00:00
|
|
|
|
|
|
|
RUN apk --no-cache add git gnupg
|
|
|
|
|
|
|
|
# Download Bitcoin
|
2023-12-12 13:20:44 +00:00
|
|
|
RUN wget https://bitcoincore.org/bin/bitcoin-core-${BITCOIN_VERSION}/bitcoin-${BITCOIN_VERSION}-$(uname -m)-linux-gnu.tar.gz \
|
2023-11-13 04:55:15 +00:00
|
|
|
&& wget https://bitcoincore.org/bin/bitcoin-core-${BITCOIN_VERSION}/SHA256SUMS \
|
|
|
|
&& wget https://bitcoincore.org/bin/bitcoin-core-${BITCOIN_VERSION}/SHA256SUMS.asc
|
|
|
|
|
|
|
|
# Verify all sigs and check for a valid signature from laanwj -- 71A3
|
|
|
|
RUN git clone https://github.com/bitcoin-core/guix.sigs && \
|
|
|
|
cd guix.sigs/builder-keys && \
|
|
|
|
find . -iname '*.gpg' -exec gpg --import {} \; && \
|
|
|
|
gpg --verify --status-fd 1 --verify ../../SHA256SUMS.asc ../../SHA256SUMS | grep "^\[GNUPG:\] VALIDSIG.*71A3B16735405025D447E8F274810B012346C9A6"
|
|
|
|
|
2023-12-12 13:20:44 +00:00
|
|
|
RUN grep bitcoin-${BITCOIN_VERSION}-$(uname -m)-linux-gnu.tar.gz SHA256SUMS | sha256sum -c
|
2023-11-13 04:55:15 +00:00
|
|
|
|
|
|
|
# Prepare Image
|
2023-12-12 13:20:44 +00:00
|
|
|
RUN tar xzvf bitcoin-${BITCOIN_VERSION}-$(uname -m)-linux-gnu.tar.gz
|
2023-11-13 04:55:15 +00:00
|
|
|
RUN mv bitcoin-${BITCOIN_VERSION}/bin/bitcoind .
|