vuln-aggregator/Dockerfile
2024-12-19 14:00:22 +03:00

28 lines
652 B
Docker

FROM rust:1.82.0 AS builder
WORKDIR /app
RUN apt update && apt install lld clang -y
RUN wget https://github.com/project-zot/zot/releases/download/v2.1.1/zli-linux-amd64 -O zli
RUN chmod +x zli
COPY . .
RUN cargo build --release
FROM rust:1.82.0-slim AS runtime
WORKDIR /app
RUN apt-get update && apt-get install -y ca-certificates && update-ca-certificates
COPY src/router/templates/ /app/templates/
ENV TEMPLATE_DIR=/app/templates
COPY configuration.yaml /app/configuration.yaml
COPY --from=builder /app/target/release/vuln-aggregator vuln-aggregator
COPY --from=builder /app/zli zli
ENV PATH="/app:${PATH}"
ENTRYPOINT ["./vuln-aggregator"]