-
Notifications
You must be signed in to change notification settings - Fork 132
Open
Description
I'm building some example code using:
FROM chef AS planner
COPY . .
RUN cargo chef prepare --recipe-path recipe.json --bin my-example
FROM chef AS builder
COPY --from=planner /app/recipe.json recipe.json
RUN cargo chef cook --release --recipe-path recipe.json
COPY . .
RUN cargo build --release -p my-example --example my-example
And sadly it seems the dependencies that are being compiled by the cook step are not the same ones as the ones used by cargo build --example my-example, and so it's rebuilding it all.
I've found that cook supports --examples, but it seems sometimes it's not always building all the required dependencies for my example binaries, it allows to not rebuild all the dependencies, however, only a few.
Metadata
Metadata
Assignees
Labels
No labels