# Cargo chef plan
FROM $RUST_BUILDER_IMAGE as planner
WORKDIR /app
-RUN cargo install cargo-chef --version 0.1.6
+RUN cargo install cargo-chef
# Copy dirs
COPY ./ ./
FROM $RUST_BUILDER_IMAGE as cacher
ARG CARGO_BUILD_TARGET=x86_64-unknown-linux-musl
WORKDIR /app
-RUN cargo install cargo-chef --version 0.1.6
+RUN cargo install cargo-chef
COPY --from=planner /app/recipe.json ./recipe.json
RUN sudo chown -R rust:rust .
RUN cargo chef cook --target ${CARGO_BUILD_TARGET} --recipe-path recipe.json
# Cargo chef plan
FROM $RUST_BUILDER_IMAGE as planner
WORKDIR /app
-RUN cargo install cargo-chef --version 0.1.6
+RUN cargo install cargo-chef
# Copy dirs
COPY ./ ./
FROM $RUST_BUILDER_IMAGE as cacher
ARG CARGO_BUILD_TARGET=x86_64-unknown-linux-musl
WORKDIR /app
-RUN cargo install cargo-chef --version 0.1.6
+RUN cargo install cargo-chef
COPY --from=planner /app/recipe.json ./recipe.json
RUN sudo chown -R rust:rust .
RUN cargo chef cook --release --target ${CARGO_BUILD_TARGET} --recipe-path recipe.json