linuxkit/pkg/node_exporter/Dockerfile
Avi Deitcher 76b519705b
Add alpine bcc tools (#4105)
* Update linuxkit/alpine

Signed-off-by: Avi Deitcher <avi@deitcher.net>

* tools/alpine: Update to latest

Signed-off-by: Avi Deitcher <avi@deitcher.net>

* tools: Update to the latest linuxkit/alpine

Signed-off-by: Avi Deitcher <avi@deitcher.net>

* Update use of tools to latest

Signed-off-by: Avi Deitcher <avi@deitcher.net>

* tests: Update packages to the latest linuxkit/alpine

Signed-off-by: Avi Deitcher <avi@deitcher.net>

* Update use of test packages to latest

Signed-off-by: Avi Deitcher <avi@deitcher.net>

* pkgs: Update packages to the latest linuxkit/alpine

Signed-off-by: Avi Deitcher <avi@deitcher.net>

* Update package tags

Signed-off-by: Avi Deitcher <avi@deitcher.net>

---------

Signed-off-by: Avi Deitcher <avi@deitcher.net>
2025-02-17 11:12:49 +02:00

29 lines
817 B
Docker

FROM linuxkit/alpine:35b33c6b03c40e51046c3b053dd131a68a26c37a as build
RUN apk add --no-cache go git musl-dev make curl gcc
ENV GOPATH=/go PATH=$PATH:/go/bin
ENV GITBASE=github.com/prometheus
ENV GITREPO=github.com/prometheus/node_exporter
ENV COMMIT=v1.8.2
RUN mkdir -p /go/src/${GITBASE} \
&& cd /go/src/${GITBASE} \
&& git clone https://${GITREPO}.git \
&& cd /go/src/${GITREPO} \
&& git checkout ${COMMIT} \
&& CGO_ENABLED=0 make build \
&& mv node_exporter /bin/
FROM scratch
ENTRYPOINT []
CMD []
WORKDIR /
COPY --from=build /bin/node_exporter /bin/node_exporter
ENTRYPOINT ["/bin/node_exporter", "--path.procfs", "/host/proc", \
"--path.sysfs", "/host/sys", \
"--collector.filesystem.ignored-mount-points", \
"^/(sys|proc|dev|host|etc)($|/)"]