Linux运维笔记
我们一直在努力

Docker报错 http: server gave HTTP response to HTTPS client

Docker Push 时报错:

docker push 172.17.0.2:5000/centos7 The push refers to a repository [172.17.0.2:5000/centos7] Get https://172.17.0.2:5000/v1/_ping: http: server gave HTTP response to HTTPS client

 

问题分析:


在docker 1.13 以后会对客户端要求验证https,如果没开启https会出现报错。

 

需要修改配置文件:vim /etc/docker/daemon.json

{ “insecure-registries”:[“172.17.0.2:5000”] } #里面是docker容器的IP地址和端口

 

修改好后重载以下docker:systemctl reload docker

赞(0) 打赏

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址