Skip to content
Merged
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
ef11e7d
build: bump Alpine version to 3.20
lklimek Aug 23, 2024
e010d64
fix: sccache cache conflict between alpine versions
lklimek Aug 23, 2024
74dd270
fix: cache conflict of /target between alpine versions
lklimek Aug 23, 2024
6a641f2
Merge branch 'v1.2-dev' into build/docker-alpine-3.20
lklimek Aug 30, 2024
272fc38
chore: switch to alpine 3.21
lklimek Dec 17, 2024
b269799
Merge remote-tracking branch 'origin/v1.9-dev' into build/docker-alpi…
lklimek Dec 17, 2024
5a5bd7b
chore: update Alpine to 3.21
lklimek Dec 17, 2024
5ed0015
build: update rocksdb 8.10.2 to 9.8.4
lklimek Dec 17, 2024
6839bdf
build: update wasm-bindgen-cli to 0.2.99
lklimek Dec 17, 2024
9b94e8e
build: update wasm-bindgen-cli to 0.2.99
lklimek Dec 17, 2024
a27cdb3
build: bump wasm-bindgen-futures to 0.4.49
lklimek Dec 17, 2024
7475b09
chore(wasm-dpp): fix build
lklimek Dec 17, 2024
03bd084
Merge branch 'deps/wasm-bindgen-0.2.99' into build/docker-alpine-3.20
lklimek Dec 17, 2024
b14bb5b
revert: rocksdb back to 8.10.2
lklimek Dec 17, 2024
df7064d
Merge remote-tracking branch 'origin/master' into build/docker-alpine…
lklimek Jan 29, 2025
ef009ac
build!: optimize for x86-64-v3 cpu microarchitecture (Haswell+) (#2374)
lklimek Dec 18, 2024
c5898ab
fit: trying to fix clang: error: unsupported option '-march=' for tar…
lklimek Jan 29, 2025
497d60a
build: downgrade clang and llvm to 18
lklimek Jan 29, 2025
89ef666
chore: clang 18 continued
lklimek Jan 29, 2025
deb43ac
fix: wasm32 does not build
lklimek Jan 30, 2025
4054ecf
chore: build rocksdb in 1 thread
lklimek Jan 30, 2025
11a932d
chore: remove redundant CARGO_BUILD_PROFILE
lklimek Jan 30, 2025
de8af22
chore: rocksdb -j1 again
lklimek Jan 30, 2025
a10fff7
chore: self-review
lklimek Jan 30, 2025
1bd61b3
chore: disable sccache
lklimek Jan 30, 2025
323fbaf
Revert "chore: disable sccache"
lklimek Jan 30, 2025
f257845
Merge remote-tracking branch 'origin/v2.0-dev' into build/docker-alpi…
lklimek Jan 30, 2025
d21f878
Merge branch 'v2.0-dev' into build/docker-alpine-3.20
lklimek Feb 11, 2025
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
16 changes: 14 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
# conflicts in case of parallel compilation.
# 3. Configuration variables are shared between runs using /root/env file.

ARG ALPINE_VERSION=3.18
ARG ALPINE_VERSION=3.21

# deps-${RUSTC_WRAPPER:-base}
# If one of SCCACHE_GHA_ENABLED, SCCACHE_BUCKET, SCCACHE_MEMCACHED is set, then deps-sccache is used, otherwise deps-base
Expand Down Expand Up @@ -72,6 +72,7 @@ RUN apk add --no-cache \
ca-certificates \
clang-static clang-dev \
cmake \
curl \
git \
libc-dev \
linux-headers \
Expand Down Expand Up @@ -148,7 +149,13 @@ RUN if [[ "$TARGETARCH" == "arm64" ]] ; then export PROTOC_ARCH=aarch_64; else e
ln -s /opt/protoc/bin/protoc /usr/bin/

# Switch to clang
RUN rm /usr/bin/cc && ln -s /usr/bin/clang /usr/bin/cc
# Note that CC / CXX can be updated later on (eg. when configuring sccache)
RUN rm /usr/bin/cc && \
ln -s /usr/bin/clang /usr/bin/cc
RUN <<EOS
echo "export CXX='clang++'" >> /root/env
echo "export CC='clang'" >> /root/env
EOS

ARG NODE_ENV=production
ENV NODE_ENV=${NODE_ENV}
Expand Down Expand Up @@ -287,6 +294,7 @@ git clone https://github.com/facebook/rocksdb.git -b v9.9.3 --depth 1 .
source /root/env

make -j$(nproc) static_lib

mkdir -p /opt/rocksdb/usr/local/lib
cp librocksdb.a /opt/rocksdb/usr/local/lib/
cp -r include /opt/rocksdb/usr/local/
Expand Down Expand Up @@ -492,11 +500,13 @@ WORKDIR /platform
COPY --from=build-planner /platform/recipe.json recipe.json

# Build dependencies - this is the caching Docker layer!
# Note we unset CFLAGS and CXXFLAGS as they have `-march` included, which breaks wasm32 build
RUN --mount=type=cache,sharing=shared,id=cargo_registry_index,target=${CARGO_HOME}/registry/index \
--mount=type=cache,sharing=shared,id=cargo_registry_cache,target=${CARGO_HOME}/registry/cache \
--mount=type=cache,sharing=shared,id=cargo_git,target=${CARGO_HOME}/git/db \
--mount=type=secret,id=AWS \
source /root/env && \
unset CFLAGS CXXFLAGS && \
cargo chef cook \
--recipe-path recipe.json \
--profile "$CARGO_BUILD_PROFILE" \
Expand Down Expand Up @@ -543,12 +553,14 @@ COPY --parents \
packages/dash-spv \
/platform/

# We unset CFLAGS CXXFLAGS because they hold `march` flags which break wasm32 build
RUN --mount=type=cache,sharing=shared,id=cargo_registry_index,target=${CARGO_HOME}/registry/index \
--mount=type=cache,sharing=shared,id=cargo_registry_cache,target=${CARGO_HOME}/registry/cache \
--mount=type=cache,sharing=shared,id=cargo_git,target=${CARGO_HOME}/git/db \
--mount=type=cache,sharing=shared,id=unplugged_${TARGETARCH},target=/tmp/unplugged \
--mount=type=secret,id=AWS \
source /root/env && \
unset CFLAGS CXXFLAGS && \
cp -R /tmp/unplugged /platform/.yarn/ && \
yarn install --inline-builds && \
cp -R /platform/.yarn/unplugged /tmp/ && \
Expand Down
Loading