Skip to content

Commit 8dbd433

Browse files
committed
docker/builder: make build image more general
1 parent 9ac77d3 commit 8dbd433

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

docker/builder/Dockerfile

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# Builder image used in Rust build pipelines
21
FROM ubuntu:25.04 AS base
32

43
RUN apt update && apt install -y \
@@ -64,13 +63,14 @@ RUN apt update && apt install -y \
6463
ninja-build \
6564
python3-pytest
6665

66+
WORKDIR /app
6767

68+
# Install Rust system-wide
69+
ENV RUSTUP_HOME=/usr/local/rustup \
70+
CARGO_HOME=/usr/local/cargo \
71+
PATH=/usr/local/cargo/bin:$PATH
6872

69-
USER ubuntu
73+
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | \
74+
bash -s -- -y --default-toolchain none --profile minimal
7075

71-
WORKDIR /usr/src/monad-bft
72-
73-
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | bash -s -- -y
74-
ENV PATH="/home/ubuntu/.cargo/bin:${PATH}"
75-
RUN rustup toolchain install 1.87.0-x86_64-unknown-linux-gnu
76-
ARG TRIEDB_TARGET=triedb_driver
76+
RUN chmod -R a+rwX $RUSTUP_HOME $CARGO_HOME

0 commit comments

Comments
 (0)