docker报错 无法连接registry-1.docker.io,pull镜像失败
简介: docker pull命令拉取镜像失败的解决方案 docker pull命令拉取镜像失败的解决方案一、执行docker pull命令,拉取镜像失败:Error response from daemon: Get “https://registry-1.docker.io/v2/”: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)
https://i-blog.csdnimg.cn/direct/a4c5b21029b24193a8609cc1c6e3e806.png
二、解决方案 解决的步骤如下:
[*]打开daemon.json文件
sudo nano /etc/docker/daemon.json```
2. 将其镜像地址进行替换
```bash
{
"registry-mirrors": [
"https://docker.m.daocloud.io",
"https://dockerproxy.com",
"https://registry.docker-cn.com",
"https://docker.mirrors.ustc.edu.cn",
"https://hub-mirror.c.163.com",
"https://hub.uuuadc.top",
"https://docker.anyhub.us.kg",
"https://dockerhub.jobcher.com",
"https://dockerhub.icu",
"https://docker.ckyl.me",
"https://docker.awsl9527.cn",
"https://mirror.baidubce.com"
]
}
三、重启docker服务
systemctl daemon-reload
systemctlrestart docker
免责声明:如果侵犯了您的权益,请联系站长,我们会及时删除侵权内容,谢谢合作!更多信息从访问主页:qidao123.com:ToB企服之家,中国第一个企服评测及商务社交产业平台。
页:
[1]