docker run -d -p 5000:5000 --restart=always --name registry \ -v `pwd`/data:/var/lib/registry \ registry:2
docker pull ubuntu
推他:docker tag ubuntu localhost:5000/myfirstimage
拉他:docker push localhost:5000/myfirstimage
在客戶端配置:編輯daemon.json,配置registry服務端的地址並重啓dockerdocker pull localhost:5000/myfirstimage
[root@zabbix docker]# cat /etc/docker/daemon.json
{ "insecure-registries":["192.168.36.106:5000"] }node
查看docker倉庫裏有哪些鏡像:docker
[root@zabbix docker]# curl -XGET http://192.168.36.106:5000/v2/_catalog
{"repositories":["node"]}json