Skip to content

Commit e44fab2

Browse files
authored
chore: add distroless docker image (prometheus#3592)
Signed-off-by: Julien Pivotto <291750+roidelapluie@users.noreply.github.com>
1 parent 0f5c158 commit e44fab2

1 file changed

Lines changed: 24 additions & 0 deletions

File tree

Dockerfile.distroless

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
ARG DISTROLESS_ARCH="amd64"
2+
3+
# Use DISTROLESS_ARCH for base image selection (handles armv7->arm mapping).
4+
FROM gcr.io/distroless/static-debian13:nonroot-${DISTROLESS_ARCH}
5+
# Base image sets USER to 65532:65532 (nonroot user).
6+
7+
ARG ARCH="amd64"
8+
ARG OS="linux"
9+
10+
LABEL org.opencontainers.image.authors="The Prometheus Authors"
11+
LABEL org.opencontainers.image.vendor="Prometheus"
12+
LABEL org.opencontainers.image.title="node_exporter"
13+
LABEL org.opencontainers.image.description="Prometheus exporter for hardware and OS metrics exposed by *NIX kernels"
14+
LABEL org.opencontainers.image.source="https://github.com/prometheus/node_exporter"
15+
LABEL org.opencontainers.image.url="https://github.com/prometheus/node_exporter"
16+
LABEL org.opencontainers.image.documentation="https://github.com/prometheus/node_exporter"
17+
LABEL org.opencontainers.image.licenses="Apache License 2.0"
18+
LABEL io.prometheus.image.variant="distroless"
19+
20+
COPY LICENSE NOTICE /
21+
COPY .build/${OS}-${ARCH}/node_exporter /bin/node_exporter
22+
23+
EXPOSE 9100
24+
ENTRYPOINT [ "/bin/node_exporter" ]

0 commit comments

Comments
 (0)