diff --git a/Dockerfile b/Dockerfile index 60f9617a1..bdead4f8f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -50,13 +50,11 @@ RUN mkdir -p /output/usr/bin && \ go build -o /output/${BIN} \ -ldflags "${LDFLAGS}" ${PKG}/cmd/${BIN} -FROM ubuntu:focal +FROM gcr.io/distroless/base-debian10:nonroot LABEL maintainer="Nolan Brubaker " -RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -qq -y ca-certificates tzdata && rm -rf /var/lib/apt/lists/* - COPY --from=builder /output / -USER nobody:nogroup +USER nonroot:nonroot diff --git a/changelogs/unreleased/4055-ywk253100 b/changelogs/unreleased/4055-ywk253100 new file mode 100644 index 000000000..4dd9a9c85 --- /dev/null +++ b/changelogs/unreleased/4055-ywk253100 @@ -0,0 +1 @@ +Change the base image to distroless \ No newline at end of file