下载registry镜像
docker pull registry:2
registry私有仓库运行
docker run -d -v /mnt/docker/registry/docker/registry -p 5000:5000 --restart=always --name registry docker.io/registry:2
为已有镜像打标签
docker tag XXX localhost:5000/XXX:v1.0
推送镜像给registry
docker push localhost:5000/XXX:v1.0
再次拉取该镜像可以从本地拉取
docker pull localhost:5000/bosybox:v1.0
查看私服有哪些镜像
curl http://localhost:5000/v2/_catalog