Also runs `cargo update` and moves where we install the wasm toolchain in the
Dockerfile for better caching properties.
This commit is contained in:
Luke Parker
2023-10-23 00:33:38 -04:00
parent fd1826cca9
commit fbf51e53ec
12 changed files with 250 additions and 293 deletions

View File

@@ -4,6 +4,9 @@ LABEL description="STAGE 1: Build"
# Upgrade and add dev dependencies
RUN apt update && apt upgrade -y && apt install -y git pkg-config make clang libssl-dev protobuf-compiler && apt autoremove -y && apt clean
# Add the wasm toolchain
RUN rustup target add wasm32-unknown-unknown
# Add files for build
ADD common /serai/common
ADD crypto /serai/crypto
@@ -20,9 +23,6 @@ ADD AGPL-3.0 /serai
WORKDIR /serai
# Add the wasm toolchain
RUN rustup target add wasm32-unknown-unknown
# Mount the caches and build
RUN --mount=type=cache,target=/root/.cargo \
--mount=type=cache,target=/usr/local/cargo/registry \