解决docker pull超时问题

方法1: 修改国内镜像源

1、修改daemon配置文件:vim /etc/docker/daemon.json

{
"registry-mirrors": ["https://***吴彦祖的地址***.mirror.aliyuncs.com"]
}

这里推荐几个镜像源

// docker 中国区镜像源
https://registry.docker-cn.com
// 网易镜像源
http://hub-mirror.c.163.com
// 阿里云镜像源
https://registry.cn-hangzhou.aliyuncs.com

国内可以正常访问的镜像网址,大部分镜像都有,可以作为一个应急下载源
第三方镜像-可信镜像中心网址

// 官方网址
https://atomhub.openatom.cn/

// 下载示例
docker pull atomhub.openatom.cn/amd64/redis:7.0.2

修改完daemon.json后重启docker

systemctl daemon-reload
systemctl restart docker 

方法2: 增加加速器

1、修改daemon配置文件:vim /etc/docker/daemon.json

{
"registry-mirrors": 
	[
		"https://do.nark.eu.org",
		"https://dc.j8.work",
		"https://docker.m.daocloud.io",
		"https://dockerproxy.com",
		"https://docker.mirrors.ustc.edu.cn",
		"https://docker.nju.edu.cn"
	]
}

修改完daemon.json后重启docker

systemctl daemon-reload
systemctl restart docker 

附:阿里云个人镜像加速器
网址:https://cr.console.aliyun.com/cn-hangzhou/instances/mirrors
或者搜索容器镜像服务》镜像工具》容器加速器,或者个人专属加速器

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值