diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 000000000..9abb766ce --- /dev/null +++ b/.dockerignore @@ -0,0 +1 @@ +.* \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 000000000..257bdcd86 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,14 @@ +FROM golang:1.7.5 + +MAINTAINER Pilosa Corp. + +EXPOSE 15000 +VOLUME /data + +RUN echo 'data-dir = "/data"' > /config + +COPY . /go/src/github.com/pilosa/pilosa +RUN CGO_ENABLED=0 go install -a github.com/pilosa/pilosa/cmd/pilosa + +ENTRYPOINT ["/go/bin/pilosa"] +CMD ["-config", "/config"] diff --git a/Makefile b/Makefile index 8590d3343..61abf2026 100644 --- a/Makefile +++ b/Makefile @@ -5,3 +5,6 @@ default: vendor: godep save ./... cp -r $(GOPATH)/src/github.com/gogo/protobuf/proto/testdata vendor/github.com/gogo/protobuf/proto/testdata + +docker: + docker build -t pilosa:latest .