forked from adhocteam/script_exporter
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
21 lines (16 loc) · 662 Bytes
/
Dockerfile
File metadata and controls
21 lines (16 loc) · 662 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
FROM golang:1.14.1-alpine AS build-env
RUN apk add --update git gcc libc-dev
RUN go get -u github.com/prometheus/promu
RUN mkdir script_exporter
COPY .promu.yml script_exporter.go go.mod go.sum /go/script_exporter/
WORKDIR /go/script_exporter
RUN promu build
FROM alpine:3.11
LABEL upstream="https://github.com/adhocteam/script_exporter"
LABEL maintainer="james.kassemi@adhocteam.us"
RUN apk add --no-cache bash
COPY --from=build-env /go/script_exporter/script_exporter /bin/script-exporter
COPY script-exporter.yml /etc/script-exporter/config.yml
EXPOSE 9172
ENTRYPOINT [ "/bin/script-exporter" ]
CMD ["-config.file=/etc/script-exporter/config.yml"]