diff --git a/Dockerfile b/Dockerfile index ddbb0d5..c10fc4e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,11 +13,12 @@ ENV RUSTFLAGS="-C link-arg=-fuse-ld=/mold" FROM rust-base as planner ARG SERVICE COPY . . -RUN cargo chef prepare --recipe-path recipe.json --bin ${SERVICE} +RUN cargo chef prepare --recipe-path recipe.json --bin services/${SERVICE} # Step 2: Cache project dependencies FROM rust-base as cacher ARG SERVICE +COPY . . COPY --from=planner /app/recipe.json recipe.json RUN cargo chef cook --release --recipe-path recipe.json --bin ${SERVICE}