mirror of
https://github.com/containers/skopeo.git
synced 2025-09-03 23:55:21 +00:00
20
Dockerfile
20
Dockerfile
@@ -1,14 +1,13 @@
|
|||||||
FROM fedora
|
FROM fedora
|
||||||
|
|
||||||
RUN dnf -y update && dnf install -y make git golang golang-github-cpuguy83-go-md2man golang-github-Sirupsen-logrus-devel golang-github-codegangsta-cli-devel golang-golangorg-net-devel
|
RUN dnf -y update && dnf install -y make git golang golang-github-cpuguy83-go-md2man python-pip m2crypto swig redhat-rpm-config
|
||||||
|
|
||||||
# Install two versions of the registry. The first is an older version that
|
# Install three versions of the registry. The first is an older version that
|
||||||
# only supports schema1 manifests. The second is a newer version that supports
|
# only supports schema1 manifests. The second is a newer version that supports
|
||||||
# both. This allows integration-cli tests to cover push/pull with both schema1
|
# both. This allows integration-cli tests to cover push/pull with both schema1
|
||||||
# and schema2 manifests.
|
# and schema2 manifests. Install registry v1 also.
|
||||||
ENV REGISTRY_COMMIT_SCHEMA1 ec87e9b6971d831f0eff752ddb54fb64693e51cd
|
ENV REGISTRY_COMMIT_SCHEMA1 ec87e9b6971d831f0eff752ddb54fb64693e51cd
|
||||||
ENV REGISTRY_COMMIT 47a064d4195a9b56133891bbb13620c3ac83a827
|
ENV REGISTRY_COMMIT 47a064d4195a9b56133891bbb13620c3ac83a827
|
||||||
#ENV REGISTRY_COMMIT_v1 TODO(runcom)
|
|
||||||
RUN set -x \
|
RUN set -x \
|
||||||
&& export GOPATH="$(mktemp -d)" \
|
&& export GOPATH="$(mktemp -d)" \
|
||||||
&& git clone https://github.com/docker/distribution.git "$GOPATH/src/github.com/docker/distribution" \
|
&& git clone https://github.com/docker/distribution.git "$GOPATH/src/github.com/docker/distribution" \
|
||||||
@@ -18,14 +17,17 @@ RUN set -x \
|
|||||||
&& (cd "$GOPATH/src/github.com/docker/distribution" && git checkout -q "$REGISTRY_COMMIT_SCHEMA1") \
|
&& (cd "$GOPATH/src/github.com/docker/distribution" && git checkout -q "$REGISTRY_COMMIT_SCHEMA1") \
|
||||||
&& GOPATH="$GOPATH/src/github.com/docker/distribution/Godeps/_workspace:$GOPATH" \
|
&& GOPATH="$GOPATH/src/github.com/docker/distribution/Godeps/_workspace:$GOPATH" \
|
||||||
go build -o /usr/local/bin/registry-v2-schema1 github.com/docker/distribution/cmd/registry \
|
go build -o /usr/local/bin/registry-v2-schema1 github.com/docker/distribution/cmd/registry \
|
||||||
&& rm -rf "$GOPATH"
|
&& rm -rf "$GOPATH" \
|
||||||
|
&& export DRV1="$(mktemp -d)" \
|
||||||
|
&& git clone https://github.com/docker/docker-registry.git "$DRV1" \
|
||||||
|
&& pip install --ignore-installed "$DRV1/depends/docker-registry-core" \
|
||||||
|
&& pip install --ignore-installed file://"$DRV1#egg=docker-registry[bugsnag,newrelic,cors]" \
|
||||||
|
&& patch $(python -c 'import boto; import os; print os.path.dirname(boto.__file__)')/connection.py \
|
||||||
|
< "$DRV1/contrib/boto_header_patch.diff"
|
||||||
|
|
||||||
ENV GOPATH /usr/share/gocode:/go
|
ENV GOPATH /usr/share/gocode:/go
|
||||||
WORKDIR /go/src/github.com/runcom/skopeo
|
WORKDIR /go/src/github.com/runcom/skopeo
|
||||||
|
|
||||||
#ENTRYPOINT ["hack/dind"]
|
|
||||||
|
|
||||||
COPY . /go/src/github.com/runcom/skopeo
|
COPY . /go/src/github.com/runcom/skopeo
|
||||||
|
|
||||||
# remove distro-supplied dependencies, so we build against them and the rest from vendor/
|
#ENTRYPOINT ["hack/dind"]
|
||||||
RUN rm -rf /go/src/github.com/runcom/skopeo/vendor/golang.org && rm -rf /go/src/github.com/runcom/skopeo/vendor/github.com/Sirupsen && rm -rf /go/src/github.com/runcom/skopeo/vendor/github.com/codegangsta
|
|
||||||
|
@@ -109,6 +109,8 @@ $ make test-integration
|
|||||||
```
|
```
|
||||||
TODO
|
TODO
|
||||||
-
|
-
|
||||||
|
- output raw manifest
|
||||||
|
- download layers and support docker load tar(s)
|
||||||
- get rid of docker/docker code (?)
|
- get rid of docker/docker code (?)
|
||||||
- show repo tags via flag or when reference isn't tagged or digested
|
- show repo tags via flag or when reference isn't tagged or digested
|
||||||
- add tests (integration with deployed registries in container - Docker-like)
|
- add tests (integration with deployed registries in container - Docker-like)
|
||||||
|
@@ -13,6 +13,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
binaryV1 = "docker-registry"
|
||||||
binaryV2 = "registry-v2"
|
binaryV2 = "registry-v2"
|
||||||
binaryV2Schema1 = "registry-v2-schema1"
|
binaryV2Schema1 = "registry-v2-schema1"
|
||||||
)
|
)
|
||||||
|
Reference in New Issue
Block a user