问题
今天搭建私有镜像仓库后,上传镜像时报错:
[root@server ~]# docker push 192.168.200.104:5000/rancher/agent:v1.2.5
The push refers to a repository [192.168.200.104:5000/rancher/agent]
Get https://192.168.200.104:5000/v1/_ping: http: server gave HTTP response to HTTPS client
原因:
在/etc/sysconfig/docker添加的配置信息错误,第二行的" - - insecure"打成了" - - add",正确信息是:
ADD_REGISTRY='--add-registry 192.168.200.104:5000'
INSECURE_REGISTRY='--add-registry 192.168.200.104:5000'