2024-06-24 11:15:21 +02:00
|
|
|
FROM golang:1.22 as builder
|
2021-11-30 11:31:19 +01:00
|
|
|
WORKDIR /go/src/app
|
|
|
|
COPY . .
|
|
|
|
RUN make manager
|
|
|
|
|
2019-08-21 10:12:07 +02:00
|
|
|
# Use distroless as minimal base image to package the manager binary
|
|
|
|
# Refer to https://github.com/GoogleContainerTools/distroless for more details
|
2023-08-08 10:30:24 +02:00
|
|
|
FROM gcr.io/distroless/static:nonroot
|
|
|
|
WORKDIR /
|
2021-11-30 11:31:19 +01:00
|
|
|
COPY --from=builder /go/src/app/manager .
|
2023-08-08 10:30:24 +02:00
|
|
|
USER 65532:65532
|
|
|
|
|
2019-08-21 10:12:07 +02:00
|
|
|
ENTRYPOINT ["/manager"]
|