openshfit版本 v3.11.0,通过ansible-playbook安装
1、遇到这个问题需要在/etc/docker/daemon.json中添加docker的网段: "insecure-registries": ["172.30.0.0/16"]
2、再到 /etc/containers/registries.conf下的insecure字段添加同样内容:
[registries.insecure] registries = ["172.30.0.0/16"]
3、重新启动docker
[root@~]# systemctl daemon-reload
[root@~]# systemctl restart docker
4、如果觉得默认的镜像下载速度太慢也可以使用国内的
[root@master01 mybank-demo-maven]# cat /etc/docker/daemon.json {"registry-mirrors": ["http://ef017c13.m.daocloud.io", "http://harbor.zyg.com"], "insecure-registries": ["harbor.zyg.com", "172.30.0.0/16"]}
harbor.zyg.com是我的私有镜像的地址