2018-05-15 00:41:15 +10:00
|
|
|
FROM golang:1.10-alpine
|
2015-06-01 20:15:53 +10:00
|
|
|
|
2015-01-21 14:04:19 +11:00
|
|
|
ENV DISTRIBUTION_DIR /go/src/github.com/docker/distribution
|
2016-03-11 11:46:43 +11:00
|
|
|
ENV DOCKER_BUILDTAGS include_oss include_gcs
|
2015-01-30 10:37:22 +11:00
|
|
|
|
2017-05-23 18:58:05 +10:00
|
|
|
ARG GOOS=linux
|
|
|
|
ARG GOARCH=amd64
|
|
|
|
|
2016-07-22 09:14:32 +10:00
|
|
|
RUN set -ex \
|
|
|
|
&& apk add --no-cache make git
|
|
|
|
|
2015-01-21 14:04:19 +11:00
|
|
|
WORKDIR $DISTRIBUTION_DIR
|
|
|
|
COPY . $DISTRIBUTION_DIR
|
2015-08-11 07:30:29 +10:00
|
|
|
COPY cmd/registry/config-dev.yml /etc/docker/registry/config.yml
|
2016-04-09 01:55:11 +10:00
|
|
|
|
2015-01-30 10:37:22 +11:00
|
|
|
RUN make PREFIX=/go clean binaries
|
2014-12-11 10:57:41 +11:00
|
|
|
|
2015-06-11 14:24:16 +10:00
|
|
|
VOLUME ["/var/lib/registry"]
|
2014-12-11 10:57:41 +11:00
|
|
|
EXPOSE 5000
|
2015-04-07 00:05:11 +10:00
|
|
|
ENTRYPOINT ["registry"]
|
2016-01-20 09:26:15 +11:00
|
|
|
CMD ["serve", "/etc/docker/registry/config.yml"]
|