Use entrypoint in Dockerfile
Signed-off-by: Ben Firshman <ben@firshman.co.uk>
This commit is contained in:
parent
0a2affa79f
commit
1211d499f2
@ -1,14 +1,12 @@
|
|||||||
FROM golang:1.4
|
FROM golang:1.4
|
||||||
|
|
||||||
ENV CONFIG_PATH /etc/docker/registry/config.yml
|
|
||||||
ENV DISTRIBUTION_DIR /go/src/github.com/docker/distribution
|
ENV DISTRIBUTION_DIR /go/src/github.com/docker/distribution
|
||||||
ENV GOPATH $DISTRIBUTION_DIR/Godeps/_workspace:$GOPATH
|
ENV GOPATH $DISTRIBUTION_DIR/Godeps/_workspace:$GOPATH
|
||||||
|
|
||||||
WORKDIR $DISTRIBUTION_DIR
|
WORKDIR $DISTRIBUTION_DIR
|
||||||
COPY . $DISTRIBUTION_DIR
|
COPY . $DISTRIBUTION_DIR
|
||||||
RUN make PREFIX=/go clean binaries
|
RUN make PREFIX=/go clean binaries
|
||||||
RUN mkdir -pv "$(dirname $CONFIG_PATH)"
|
|
||||||
RUN cp -lv ./cmd/registry/config.yml $CONFIG_PATH
|
|
||||||
|
|
||||||
EXPOSE 5000
|
EXPOSE 5000
|
||||||
CMD registry $CONFIG_PATH
|
ENTRYPOINT ["registry"]
|
||||||
|
CMD ["cmd/registry/config.yml"]
|
||||||
|
Loading…
Reference in New Issue
Block a user