Something went wrong. Try again.
Scalable and distributed custom feed generator, ott - on that topic
Something went wrong. Try again.
12345678910111213141516171819202122232425262728FROM rust:1 AS chef # We only pay the installation cost once, # it will be cached from the second build onwardsRUN cargo install cargo-chef WORKDIR /workspace
FROM chef AS plannerCOPY crates .RUN cargo chef prepare --recipe-path recipe.json
FROM chef AS builderARG CRATE_NAMECOPY --from=planner /workspace/recipe.json recipe.json# Build dependencies - this is the caching Docker layer!RUN cargo chef cook --release --recipe-path recipe.json# Build applicationCOPY crates .RUN cargo build --release --bin ${CRATE_NAME}
FROM debian:trixie-slim AS runtimeARG CRATE_NAME# Gah, time in my docker vm is wrongRUN apt-get update -o Acquire::Max-FutureTime=31536000 --allow-insecure-repositories --allow-releaseinfo-change-suite &&\ apt-get install -y postgresql-client && \ apt-get clean && \ rm -rf /var/lib/apt/lists/*COPY --from=builder /workspace/target/release/${CRATE_NAME} app