From fae578be4d940bb53fd66b77da0f36d4a5390724 Mon Sep 17 00:00:00 2001 From: kev Date: Sat, 12 Oct 2019 19:32:28 +0800 Subject: [PATCH] update registry --- registry/README.md | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/registry/README.md b/registry/README.md index 140ade2..e41cf31 100644 --- a/registry/README.md +++ b/registry/README.md @@ -65,16 +65,16 @@ $ docker-compose restart ## Client Setup ```bash -$ scp registry.easypi.info:fig/registry/certs/domain.crt \ - /etc/docker/certs.d/registry.easypi.info:5000/ca.crt +$ scp registry.easypi.pro:fig/registry/certs/domain.crt \ + /etc/docker/certs.d/registry.easypi.pro:5000/ca.crt $ vim /etc/docker/daemon.json { "registry-mirrors": [ - "https://registry.easypi.info:5000" + "https://registry.easypi.pro:5000" ], "insecure-registries": [ - "registry.easypi.info" + "registry.easypi.pro" ], "log-driver": "json-file", "log-opts": { @@ -87,14 +87,15 @@ $ systemctl reload docker $ docker info $ docker pull alpine -$ docker tag alpine registry.easypi.info:5000/alpine +$ docker tag alpine registry.easypi.pro:5000/alpine -$ docker login -u username -p password easypi.info:5000 -$ docker push registry.easypi.info:5000/alpine -$ docker rmi registry.easypi.info:5000/alpine -$ docker pull registry.easypi.info:5000/alpine +$ docker login -u username -p password easypi.pro:5000 +$ docker push registry.easypi.pro:5000/alpine +$ docker rmi registry.easypi.pro:5000/alpine +$ docker pull registry.easypi.pro:5000/alpine -$ firefox http://registry.easypi.info:8080 +$ curl -k -u username:password https://registry.easypi.pro:5000/v2/_catalog +$ curl -k -u username:password https://registry.easypi.pro:5000/v2/alpine/tags/list ``` > :warning: Docker will connect [insecure-registries][2] via HTTPS first (ignore TLS error), then try HTTP. @@ -105,6 +106,7 @@ $ firefox http://registry.easypi.info:8080 - https://github.com/docker/distribution/blob/master/docs/insecure.md - https://serversforhackers.com/tcp-load-balancing-with-nginx-ssl-pass-thru - https://github.com/docker/distribution/blob/master/docs/recipes/mirror.md +- https://docs.docker.com/registry/spec/api/ [1]: https://github.com/docker/distribution [2]: https://docs.docker.com/registry/insecure/#deploy-a-plain-http-registry