1、上传镜像到公有仓库
1)、登录https://hub.docker.com/ 创建账号
2)、docker images
找一个小一点的images,如hello-world
3)、打上tag
docker tag hello-world:latest larry003/hello-world:latest
larry003 是docker hub上的用户名
4)登录docker hub
docker login
5)将镜像上传
docker push larry003/hello-world:latest
2、私有仓库
1)打开 https://hub.docker.com, 搜索registry
4) 打上tag
docker tag hello-world:latest localhost:5000/hello-world:latest
5) 推送镜像
docker push localhost:5000/hello-world:latest
总结:这样私有仓库就创建起来了。
缺点:生产环境的单点问题,如果这条服务器故障了,其它服务器很难接管过来。
没有操作界面。
原文:https://www.cnblogs.com/linlf03/p/12936365.html