docker pull 镜像失败

巢睿
2023-12-01
1、question 1
 ERROR: Get https://*/v2/: http: server gave HTTP response to HTTPS client

配置 /etc/hosts

配置 /etc/docker/daemon.json

{
 "log-opts":{
       "max-size" :"50m","max-file":"3"
    },
"default-runtime": "nvidia",
"graph": "/data1/docker",
"insecure-registries" : ["域名:port","域名2:port"],
"dns":["114.114.114.114",...],
"registry-mirrors": ["https://*.mirror.aliyuncs.com"],
    "runtimes": {
        "nvidia": {
            "path": "nvidia-container-runtime",
            "runtimeArgs": []
        }
    }
}

重启加速器

  systemctl daemon-reload

重启docker

  systemctl restart docker

2、 question 2

ERROR: unauthorized: unauthorized to access repository:action: pull:

进行docker 登陆

 docker login -u userx -p 123456 域名2:port
 类似资料: