You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

40 lines
1.2 KiB

5 years ago
FROM debian:stable-slim
LABEL maintainer="Luke Childs <lukechilds123@gmail.com>"
COPY ./bin /usr/local/bin
COPY ./VERSION /tmp
RUN VERSION=`cat /tmp/VERSION` && \
TARBALL="bitcoin-${VERSION}-x86_64-linux-gnu.tar.gz" && \
5 years ago
chmod a+x /usr/local/bin/* && \
apt-get update && \
apt-get install -y curl gpg && \
cd /tmp && \
curl -O https://bitcoin.org/bin/bitcoin-core-${VERSION}/${TARBALL} && \
curl -O https://bitcoin.org/bin/bitcoin-core-${VERSION}/SHA256SUMS.asc && \
KEY=01EA5486DE18A882D4C2684590C8019E36C2E964 && \
5 years ago
for keyserver in \
keyserver.ubuntu.com \
pgp.mit.edu \
keyserver.pgp.com \
ha.pool.sks-keyservers.net \
hkp://p80.pool.sks-keyservers.net:80; \
do \
timeout 5s gpg --keyserver $keyserver --recv-keys $KEY && break; \
done && \
gpg --verify SHA256SUMS.asc && \
grep $TARBALL SHA256SUMS.asc | sha256sum -c && \
tar -zxvf $TARBALL && \
mv bitcoin-${VERSION}/bin/* /usr/local/bin/ && \
apt-get purge -y curl gpg && \
5 years ago
apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
VOLUME ["/data"]
ENV HOME /data
ENV DATA /data
WORKDIR /data
EXPOSE 8332 8333
ENTRYPOINT ["init"]