# Build binary FROM rust:1.75.0 as build-env WORKDIR /app COPY . /app RUN cargo build --release # Copy binary to distroless CC # Specs: https://edu.chainguard.dev/chainguard/chainguard-images/reference/glibc-dynamic/image_specs/ FROM cgr.dev/chainguard/glibc-dynamic:latest COPY --from=build-env /app/target/release/sontonio-iam / # TODO: Handle SIGINT gracefully in app ^C ENV PORT="3000" EXPOSE ${PORT} CMD ["./sontonio-iam"]