@@ -2,15 +2,17 @@ FROM alpine:3.22 AS builder
22
33RUN apk add --no-cache \
44 build-base \
5+ gnupg \
6+ cmake \
57 boost-dev \
68 libevent-dev \
79 sqlite-dev \
8- gnupg \
10+ zeromq-dev \
911 coreutils \
1012 binutils
1113
12- ARG MAJOR_VERSION=28
13- ARG VERSION=28 .1.knots20250305
14+ ARG MAJOR_VERSION=29
15+ ARG VERSION=29 .1.knots20250903
1416ARG BASE_URL=https://bitcoinknots.org/files/${MAJOR_VERSION}.x/${VERSION}
1517ARG TARBALL=bitcoin-${VERSION}.tar.gz
1618
@@ -27,30 +29,31 @@ RUN gpg --import gpg/* && \
2729
2830RUN tar xzf ${TARBALL} --strip-components=1
2931
30- RUN CXXFLAGS="-march=native" ./configure \
31- --quiet \
32- --bindir=/opt/bitcoin/bin \
33- --with-daemon \
34- --disable-util-tx \
35- --disable-util-wallet \
36- --disable-util-util \
37- --disable-wallet \
38- --disable-zmq \
39- --disable-fuzz-binary \
40- --disable-debug \
41- --disable-tests \
42- --disable-bench \
43- --disable-man \
44- --disable-ccache \
45- --disable-dependency-tracking \
46- --without-libs \
47- --without-gui \
48- --without-bdb
49-
50- RUN make -j$(nproc)
51- RUN make install
52-
53- RUN strip --strip-unneeded /opt/bitcoin/bin/*
32+ WORKDIR /opt/bitcoin/build
33+
34+ RUN cmake .. \
35+ -DCMAKE_INSTALL_PREFIX="/usr/local/" \
36+ -DBUILD_DAEMON="ON" \
37+ -DBUILD_CLI="ON" \
38+ -DENABLE_WALLET="OFF" \
39+ -DWITH_ZMQ="OFF" \
40+ -DBUILD_TESTS="OFF" \
41+ -DBUILD_GUI="OFF" \
42+ -DBUILD_TX="OFF" \
43+ -DBUILD_UTIL="OFF" \
44+ -DBUILD_WALLET_TOOL="OFF" \
45+ -DBUILD_BENCH="OFF" \
46+ -DBUILD_FUZZ_BINARY="OFF" \
47+ -DBUILD_UTIL_CHAINSTATE="OFF" \
48+ -DWITH_BDB="OFF" \
49+ -DWITH_USDT="OFF" \
50+ -DINSTALL_MAN="OFF" \
51+ -DWITH_CCACHE="OFF"
52+
53+ RUN cmake --build . --parallel $(nproc)
54+ RUN cmake --install .
55+
56+ RUN strip --strip-unneeded /usr/local/bin/*
5457
5558FROM alpine:3.22
5659
@@ -61,8 +64,8 @@ RUN apk add --no-cache \
6164 boost-filesystem \
6265 boost-program_options
6366
64- COPY --from=builder /opt/bitcoin /bin/ /usr/local/bin/
65- COPY bitcoin.conf /etc/bitcoin/bitcoin.conf
67+ COPY --from=builder /usr/local /bin/ /usr/local/bin/
68+ COPY bitcoin.conf /etc/bitcoin/bitcoin.conf
6669
6770WORKDIR /var/lib/bitcoin
6871EXPOSE 8332
0 commit comments