Skip to content

Commit

Permalink
backport Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
segfaultdoc committed Mar 16, 2023
1 parent 9b6d9a1 commit 40a2022
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions dev/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM rust:1.63.0
FROM rust:1.64-slim-bullseye as builder

# Add Google Protocol Buffers for Libra's metrics library.
ENV PROTOC_VERSION 3.8.0
Expand All @@ -15,7 +15,7 @@ RUN set -x \
libssl-dev \
pkg-config \
zlib1g-dev \
make \
curl \
&& rustup component add rustfmt \
&& rustup component add clippy \
&& rustc --version \
Expand All @@ -30,9 +30,6 @@ WORKDIR /solana
COPY . .
RUN mkdir -p docker-output

ARG ci_commit
ENV CI_COMMIT=$ci_commit

ARG debug

# Uses docker buildkit to cache the image.
Expand All @@ -45,3 +42,8 @@ RUN --mount=type=cache,mode=0777,target=/solana/target \
else \
RUSTFLAGS='-g -C force-frame-pointers=yes' ./cargo stable build --release && cp target/release/solana* ./docker-output; \
fi


# keep CI_COMMIT at bottom since it breaks caching: https://stackoverflow.com/a/57017745/3408577
ARG ci_commit
ENV CI_COMMIT=$ci_commit

0 comments on commit 40a2022

Please sign in to comment.