capture/Dockerfile
Simon Vieille cf97958081
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
optimze the docker build
2023-06-09 11:31:49 +02:00

16 lines
314 B
Docker

FROM golang:1.19 as builder
WORKDIR /src
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN CGO_ENABLED=0 GOOS=linux go build -o /app/capture
FROM debian:stable-slim
RUN apt-get update && apt-get install -y ca-certificates
COPY --from=builder /app/capture /usr/bin/capture
ENTRYPOINT ["/usr/bin/capture"]