0%

Docker配置加速器 - 晓晨Master - 博客园

Excerpt

我们国内使用官方Docker Hub仓库实在是太慢了,很影响效率 使用命令编辑文件: 加入下面的数据: docker cn镜像: https://www.docker cn.com/registry mirror 如果你是腾讯云的服务器那么请加入: 阿里云的服务器请查看:https://yq.ali


我们国内使用官方Docker Hub仓库实在是太慢了,很影响效率

使用命令编辑文件:

1
vim /etc/docker/daemon.json

加入下面的数据:

docker-cn镜像:

1
{ "registry-mirrors": ["https://registry.docker-cn.com"] }

https://www.docker-cn.com/registry-mirror

如果你是腾讯云的服务器那么请加入:

1
{ "registry-mirrors": ["https://mirror.ccs.tencentyun.com"] }

阿里云的服务器请查看:https://yq.aliyun.com/articles/29941

wq保存退出:

执行命令生效:

1
systemctl daemon-reload systemctl restart docker

以上两个源,我都测试过,如果你是腾讯云那么肯定用腾讯云的源最好,阿里同样,速度飞快 image 秒 pull。