本地docker registry的https错误解决
程序员文章站
2023-12-30 12:24:52
...
从docker1.3.2版本开始默认docker registry使用的是https,当你用docker pull 非https的docker regsitry的时候会报下面错误:
Error: Invalid registry endpoint ... Get ... If this private registry supports only HTTP or HTTPS with an unknown CA certificate, please add '--insecure-registry 192.168.1.103:5000' to the daemon's arguments. In the case of HTTPS, if you have access to the registry's CA certificate, no need for the flag; simply place the CA certificate at /etc/docker/certs.d/192.168.1.103:5000/ca.crt
解决方案:
vi /usr/lib/systemd/system/docker.service
内容修改如下:
[Unit] Description=Docker Application Container Engine Documentation=http://docs.docker.com After=network.target docker.socket Requires=docker.socket [Service] Type=notify EnvironmentFile=-/etc/sysconfig/docker EnvironmentFile=-/etc/sysconfig/docker-storage ExecStart=/usr/bin/docker -d --insecure-registry 192.168.1.103:5000 -H fd:// $OPTIONS $DOCKER_STORAGE_OPTIONS LimitNOFILE=1048576 LimitNPROC=1048576 [Install] WantedBy=multi-user.target
推荐阅读
-
本地docker registry的https错误解决
-
vsftpd本地用户登录密码错误的解决方法
-
利用Docker搭建本地https环境的完整步骤
-
安装Docker时错误提示 "could not change group /var/run/docker.sock to docker: group docker not found"的解决方案
-
Android webview加载https链接错误或无响应的解决
-
vsftpd本地用户登录密码错误的解决方法
-
win7系统打开本地连接属性提示网络连接出现意外错误的故障原因及解决方法
-
解决Docker x509 insecure registry的问题
-
未在本地计算机上注册“Microsoft.Jet.OleDb.4.0”提供程序错误的解决方法
-
docker 搭建本地的 Registry