1.安装过docker后
2.安装仓库 docker run -d -p 5000:5000 -v /opt/registry/data:/var/lib/registry --privileged=true --restart=always --name registry registry:latest
3.http://192.168.232.25:5000/v2/ 判断是否安装成功
4.制作一个镜像docker pull busybox
5.打个tag docker tag docker.io/busybox:latest 192.168.232.25:5000/busybox:latest
6.将镜像提交到仓库 docker push 192.168.232.25:5000/busybox:latest
备注:The push refers to a repository [192.168.232.25:5000/busybox]
Get https://192.168.232.25:5000/v1/_ping: http: server gave HTTP response to HTTPS client
7. 当前docker 服务器上配置(不是私服机器)
/etc/docker/daemon.json
{
"registry-mirrors": [
"http://68cdf6cf.m.daocloud.io"
],
"insecure-registries":["192.168.232.25:5000"]
}
8.重启docker
9.重启仓库