@@ -21,7 +21,6 @@ ENV DEBIAN_FRONTEND noninteractive
2121CMD ["/bin/bash" ]
2222
2323ARG WGET_VERSION="1.21.3-1+b2"
24- ARG OPENJDK_17_VERSION="17.0.11+9-1~deb12u1"
2524ARG VERSION_BRANCH=""
2625ARG VERSION_COMMIT=""
2726ARG VERSION_DISPLAY=""
@@ -46,18 +45,18 @@ ENV VERSION_LAST_TAG=$VERSION_LAST_TAG
4645# - https://packages.debian.org/bookworm/pkg-config
4746# - https://packages.debian.org/bookworm/unzip
4847# - https://packages.debian.org/bookworm/wget
49- # - https://packages.debian.org/bookworm/software-properties-commo
48+ # - https://packages.debian.org/bookworm/software-properties-common
5049# - https://packages.debian.org/bookworm/openjdk-17-jdk
5150RUN apt-get update \
5251 && apt-get install -y --no-install-recommends \
5352 docker.io=20.10.24+dfsg1-1+b3 \
54- libssl-dev=3.0.11 -1~deb12u2 \
53+ libssl-dev=3.0.13 -1~deb12u1 \
5554 pkg-config=1.8.1-1 \
5655 unzip=6.0-28 \
5756 wget=${WGET_VERSION} \
58- software-properties-common=0.99.30-4 \
57+ software-properties-common=0.99.30-4.1~deb12u1 \
5958 && apt-get install -y --no-install-recommends \
60- openjdk-17-jdk=${OPENJDK_17_VERSION} \
59+ openjdk-17-jdk=17.0.11+9-1~deb12u1 \
6160 && apt-get clean \
6261 && rm -rf /var/lib/apt/lists/*
6362
@@ -104,7 +103,7 @@ COPY --from=java-build-stage /radixdlt/core/build/distributions /
104103# LAYER: library-build-stage-base
105104# Creates the base image for building the rust library
106105# =================================================================================================
107- FROM debian:12.1-slim as library-build-stage-base
106+ FROM debian:12.1-slim AS library-build-stage-base
108107WORKDIR /app
109108
110109
@@ -127,19 +126,19 @@ RUN apt-get update \
127126 ca-certificates \
128127 build-essential=12.9 \
129128 # https://security-tracker.debian.org/tracker/CVE-2023-38545
130- curl=7.88.1-10+deb12u5 \
129+ curl=7.88.1-10+deb12u6 \
131130 g++-aarch64-linux-gnu \
132131 g++-x86-64-linux-gnu \
133132 libc6-dev-arm64-cross=2.36-8cross1 \
134133 libclang-dev=1:14.0-55.7~deb12u1 \
135- libssl-dev=3.0.11 -1~deb12u2 \
134+ libssl-dev=3.0.13 -1~deb12u1 \
136135 pkg-config=1.8.1-1 \
137136 && rm -rf /var/lib/apt/lists/*
138137
139138# We fix the version of Rust here to ensure that we can update it without having
140139# issues with the caching layers containing outdated versions which aren't compatible.
141140RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs -o rustup.sh \
142- && sh rustup.sh -y --target 1.71.1-aarch64-unknown-linux-gnu 1.71.1-x86_64-unknown-linux-gnu
141+ && sh rustup.sh -y --target 1.71.1-aarch64-unknown-linux-gnu 1.71.1-x86_64-unknown-linux-gnu --default-toolchain 1.77.2
143142
144143RUN "$HOME/.cargo/bin/cargo" install sccache --version 0.7.4
145144
@@ -153,7 +152,7 @@ ENV RUSTC_WRAPPER=/root/.cargo/bin/sccache
153152# Specifically - the Rust isn't built as part of the image, instead the CMD of the image is to do the build.
154153# It allows us to use volumes at runtime to cache the build dependencies and artifacts.
155154# =================================================================================================
156- FROM library-build-stage-base as library-builder-local
155+ FROM library-build-stage-base AS library-builder-local
157156WORKDIR /app
158157
159158COPY docker/build_scripts/cargo_local_build.sh /opt/radixdlt/cargo_local_build.sh
@@ -167,7 +166,7 @@ CMD ["/opt/radixdlt/cargo_local_build.sh"]
167166# LAYER: library-build-stage-cache-packages
168167# This layer allows us to cache the compilation of all our rust dependencies in a Docker layer
169168# =================================================================================================
170- FROM library-build-stage-base as library-build-stage-cache-packages
169+ FROM library-build-stage-base AS library-build-stage-cache-packages
171170
172171WORKDIR /app
173172
@@ -205,7 +204,7 @@ RUN --mount=type=cache,id=radixdlt-babylon-node-rust-cache,target=/root/.cache/s
205204# LAYER: library-build-stage
206205# The actual build of the library
207206# =================================================================================================
208- FROM library-build-stage-cache-packages as library-build-stage
207+ FROM library-build-stage-cache-packages AS library-build-stage
209208
210209# Tidy up from the previous layer
211210RUN rm -rf core-api-server engine-state-api-server jni-export node-common state-manager
@@ -226,20 +225,18 @@ RUN --mount=type=cache,id=radixdlt-babylon-node-rust-cache,target=/root/.cache/s
226225# LAYER: library-container
227226# A layer containing just the built library at the root: /libcorerust.so
228227# =================================================================================================
229- FROM scratch as library-container
228+ FROM scratch AS library-container
230229COPY --from=library-build-stage /libcorerust.so /
231230
232231# =================================================================================================
233232# LAYER: app-container
234233# The application container which will actually run the application
235234# =================================================================================================
236- FROM debian:12.1-slim as app-container
235+ FROM debian:12.1-slim AS app-container
237236
238237LABEL org.opencontainers.image.source="https://github.com/radixdlt/babylon-node"
239238LABEL org.opencontainers.image.authors="devops@radixdlt.com"
240239
241- ARG OPENJDK_17_VERSION="17.0.11+9-1~deb12u1"
242-
243240# Install dependencies needed for building the image or running the application
244241# - unzip is needed for unpacking the java build artifacts
245242# - daemontools is needed at application runtime for async tasks
@@ -259,16 +256,16 @@ ARG OPENJDK_17_VERSION="17.0.11+9-1~deb12u1"
259256# - https://packages.debian.org/bookworm/libc6
260257RUN apt-get update -y \
261258 && apt-get -y --no-install-recommends install \
262- openjdk-17-jre-headless=${OPENJDK_17_VERSION} \
259+ openjdk-17-jre-headless=17.0.11+9-1~deb12u1 \
263260 # https://security-tracker.debian.org/tracker/CVE-2023-38545
264- curl=7.88.1-10+deb12u5 \
261+ curl=7.88.1-10+deb12u6 \
265262 gettext-base=0.21-12 \
266263 daemontools=1:0.76-8.1 \
267264 # https://security-tracker.debian.org/tracker/CVE-2023-4911
268265 # Fixes CVE-2023-4911 can be removed when we update the base OS image to include this fix
269266 # docker run -it debian:12.1-slim ldd --version
270267 # This fix can be removed as long as the version printed in the above command is 2.36-9+deb12u3 or above
271- libc6=2.36-9+deb12u4 \
268+ libc6=2.36-9+deb12u7 \
272269 && apt-get clean \
273270 && rm -rf /var/lib/apt/lists/*
274271
@@ -322,4 +319,4 @@ COPY docker/build_scripts/config_radixdlt.sh /opt/radixdlt/config_radixdlt.sh
322319
323320# See https://docs.docker.com/engine/reference/builder/#entrypoint
324321ENTRYPOINT ["/opt/radixdlt/config_radixdlt.sh" ]
325- CMD ["/opt/radixdlt/bin/core" ]
322+ CMD ["/opt/radixdlt/bin/core" ]
0 commit comments