From 52cf07ee8604a618fede44728001e09f8b4b2f9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Tudur=C3=AD?= Date: Mon, 18 Nov 2024 18:31:22 +0100 Subject: [PATCH] Only for Beyla (#1373) --- k8scache.Dockerfile | 4 +--- test/integration/components/beyla-k8s-cache/Dockerfile | 3 +-- test/integration/components/beyla/Dockerfile | 3 +-- test/integration/components/beyla/Dockerfile_dbg | 3 +-- 4 files changed, 4 insertions(+), 9 deletions(-) diff --git a/k8scache.Dockerfile b/k8scache.Dockerfile index afc4b0a47..b9c5ec976 100644 --- a/k8scache.Dockerfile +++ b/k8scache.Dockerfile @@ -22,7 +22,7 @@ COPY .git/ .git/ RUN make compile-cache # Create final image from minimal + built binary -FROM debian:bookworm-slim +FROM scratch LABEL maintainer="Grafana Labs " @@ -33,6 +33,4 @@ COPY --from=builder /opt/app-root/LICENSE . COPY --from=builder /opt/app-root/NOTICE . COPY --from=builder /opt/app-root/third_party_licenses.csv . -USER 0:0 - ENTRYPOINT [ "/k8s-cache" ] \ No newline at end of file diff --git a/test/integration/components/beyla-k8s-cache/Dockerfile b/test/integration/components/beyla-k8s-cache/Dockerfile index 6c51f9640..d5239fa23 100644 --- a/test/integration/components/beyla-k8s-cache/Dockerfile +++ b/test/integration/components/beyla-k8s-cache/Dockerfile @@ -23,10 +23,9 @@ COPY Makefile Makefile RUN make compile-cache-for-coverage # Create final image from minimal + built binary -FROM debian:bookworm-slim +FROM scratch WORKDIR / COPY --from=builder /src/bin/k8s-cache . -USER 0:0 ENTRYPOINT [ "/k8s-cache" ] \ No newline at end of file diff --git a/test/integration/components/beyla/Dockerfile b/test/integration/components/beyla/Dockerfile index ff88efaac..8233654b4 100644 --- a/test/integration/components/beyla/Dockerfile +++ b/test/integration/components/beyla/Dockerfile @@ -23,10 +23,9 @@ COPY Makefile Makefile RUN make compile-for-coverage # Create final image from minimal + built binary -FROM debian:bookworm-slim +FROM scratch WORKDIR / COPY --from=builder /src/bin/beyla . -USER 0:0 ENTRYPOINT [ "/beyla" ] \ No newline at end of file diff --git a/test/integration/components/beyla/Dockerfile_dbg b/test/integration/components/beyla/Dockerfile_dbg index ebc2cbfe5..5db969f1f 100644 --- a/test/integration/components/beyla/Dockerfile_dbg +++ b/test/integration/components/beyla/Dockerfile_dbg @@ -26,13 +26,12 @@ COPY Makefile Makefile # Build RUN make compile-for-coverage -FROM debian:bookworm-slim +FROM scratch # Copy the native executable into the containers COPY --from=builder /src/bin/beyla /beyla COPY --from=builder /beyla_wrapper.sh /beyla_wrapper.sh WORKDIR / -USER 0:0 ENTRYPOINT [ "/beyla_wrapper.sh" ] \ No newline at end of file