From 13e9b5ee8b59722e9fc404b184247fa75caa9047 Mon Sep 17 00:00:00 2001 From: Johannes 'fish' Ziemke Date: Thu, 18 Dec 2014 13:12:02 +0100 Subject: [PATCH] Simplify Dockerfile by using golang:onbuild image --- Dockerfile | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/Dockerfile b/Dockerfile index 38f14547..91913464 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,16 +1,6 @@ -FROM ubuntu:13.10 +FROM golang:onbuild MAINTAINER Prometheus Team -RUN apt-get update && apt-get install -yq curl git mercurial gcc -RUN curl -s https://go.googlecode.com/files/go1.2.linux-amd64.tar.gz | tar -C /usr/local -xzf - -ENV PATH /usr/local/go/bin:$PATH -ENV GOPATH /go - -ADD . /usr/src/node_exporter -RUN cd /usr/src/node_exporter && \ - go get -d && go build && cp node_exporter / -RUN printf '{ "scrapeInterval": 10, "attributes": {} }' > \ - node_exporter.conf - -ENTRYPOINT [ "/node_exporter" ] +ENTRYPOINT [ "go-wrapper", "run" ] +CMD [ "-logtostderr" ] EXPOSE 8080