FROM docker.io/rust:slim-bullseye as builder WORKDIR /app RUN apt update && apt install libssl-dev pkg-config libsqlite3-dev -y RUN cargo install cargo-prefetch RUN cargo prefetch COPY Cargo* /app/ COPY src /app/src RUN cargo build --release FROM docker.io/debian:bullseye-slim COPY --from=builder /app/target/release/vavbot /vavbot RUN apt update && apt install openssl sqlite3 ca-certificates -y CMD [ "/vavbot" ]