forked from burningalchemist/sql_exporter
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Neaj Morshad <[email protected]>
- Loading branch information
1 parent
54bca5a
commit 193ec60
Showing
1 changed file
with
7 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,17 +2,20 @@ ARG ARCH="amd64" | |
ARG OS="linux" | ||
FROM quay.io/prometheus/golang-builder AS builder | ||
|
||
# Get sql_exporter | ||
ADD . /go/src/github.com/burningalchemist/sql_exporter | ||
WORKDIR /go/src/github.com/burningalchemist/sql_exporter | ||
# Get sql_exporter fork | ||
ADD . /go/src/github.com/kubedb/mssqlserver_exporter | ||
WORKDIR /go/src/github.com/kubedb/mssqlserver_exporter | ||
|
||
# Do makefile | ||
RUN make | ||
|
||
# Make image and copy build sql_exporter | ||
FROM quay.io/prometheus/busybox-${OS}-${ARCH}:latest | ||
LABEL maintainer="The Prometheus Authors <[email protected]>" | ||
COPY --from=builder /go/src/github.com/burningalchemist/sql_exporter/sql_exporter /bin/sql_exporter | ||
COPY --from=builder /go/src/github.com/kubedb/mssqlserver_exporter/sql_exporter /bin/sql_exporter | ||
|
||
# Add kubedb configuration files to /etc/sql-exporter/ | ||
ADD kubedb /etc/sql-exporter/ | ||
|
||
EXPOSE 9399 | ||
USER nobody | ||
|