Skip to content

Commit

Permalink
Switch to alpine docker image, related to sosedoff#164
Browse files Browse the repository at this point in the history
  • Loading branch information
sosedoff committed Jun 28, 2016
1 parent 80f2641 commit 76622dc
Showing 1 changed file with 13 additions and 8 deletions.
21 changes: 13 additions & 8 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
FROM golang:1.5
FROM alpine:3.3
MAINTAINER Dan Sosedoff <[email protected]>

COPY . /go/src/github.com/sosedoff/pgweb
WORKDIR /go/src/github.com/sosedoff/pgweb
ENV PGWEB_VERSION 0.9.2

RUN go get github.com/tools/godep

RUN godep restore
RUN godep go build && godep go install
RUN \
apk update && \
apk add ca-certificates && \
update-ca-certificates && \
cd /tmp && \
wget https://github.com/sosedoff/pgweb/releases/download/v$PGWEB_VERSION/pgweb_linux_amd64.zip && \
unzip pgweb_linux_amd64.zip -d /usr/bin && \
mv /usr/bin/pgweb_linux_amd64 /usr/bin/pgweb && \
rm -f pgweb_linux_amd64.zip

EXPOSE 8081
CMD ["pgweb", "--bind", "0.0.0.0"]
CMD ["/usr/bin/pgweb", "--bind=0.0.0.0", "--listen=8081"]

0 comments on commit 76622dc

Please sign in to comment.