1- FROM rust:1-bullseye as builder
1+ FROM rust:1-bookworm as builder
22
33RUN rustup update && \
44 rustup default nightly-2024-01-10 && \
55 rustup component add --toolchain nightly-2024-01-10 rustfmt;
66
77RUN apt update \
8- && apt upgrade -y \
9- && DEBIAN_FRONTEND=noninteractive apt-get install -y software-properties-common pkg-config wget gnupg git apt-transport-https ca-certificates \
10- && wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - \
11- && add-apt-repository "deb https://apt.llvm.org/bullseye/ llvm-toolchain-bullseye-18 main" \
12- && apt update \
13- && apt install -y git llvm-18 clang-18 libclang-18-dev clang-18 cmake \
14- && rm -rf /var/lib/apt/lists/*;
8+ && apt upgrade -y \
9+ && DEBIAN_FRONTEND=noninteractive apt-get install -y software-properties-common pkg-config wget gnupg git apt-transport-https ca-certificates \
10+ && wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - \
11+ # https://github.com/llvm/llvm-project/issues/62475 \
12+ # add it twice to workaround:
13+ && add-apt-repository --yes "deb https://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-18 main" \
14+ && add-apt-repository --yes "deb https://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-18 main" \
15+ && sleep 5 \
16+ && apt update \
17+ && apt install -y git llvm-18 clang-18 libclang-18-dev clang-18 cmake \
18+ && rm -rf /var/lib/apt/lists/*;
1519
1620RUN update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-18 100
1721RUN update-alternatives --install /usr/bin/clang clang /usr/bin/clang-18 100
@@ -35,21 +39,21 @@ RUN mkdir -p cubestore/src/bin && \
3539
3640ARG WITH_AVX2=1
3741RUN [ "$WITH_AVX2" -eq "1" ] && export RUSTFLAGS="-C target-feature=+avx2" ; \
38- cargo build --release -p cubestore
42+ cargo build --release -p cubestore
3943
4044# Cube Store get version from his own package
4145COPY package.json package.json
4246COPY cubestore cubestore
4347RUN [ "$WITH_AVX2" -eq "1" ] && export RUSTFLAGS="-C target-feature=+avx2" ; \
44- cargo build --release -p cubestore
48+ cargo build --release -p cubestore
4549
46- FROM debian:bullseye -slim
50+ FROM debian:bookworm -slim
4751
4852WORKDIR /cube
4953
5054RUN set -ex; \
51- apt-get update; \
52- apt-get install -y libssl1.1 curl
55+ apt-get update; \
56+ apt-get install -y libssl3 curl
5357
5458COPY --from=builder /build/cubestore/target/release/cubestored .
5559
0 commit comments