Docker配置镜像仓库
- 国外的镜像仓库下载的的很慢,还有可能链接不上,所以最好更改为国内的镜像仓库
- 修改/或新增: /etc/docker/daemon.json文件
{
"registry-mirrors": ["https://docker.mirrors.ustc.edu.cn", "https://cr.console.aliyun.com", "https://registry.docker-cn.com"],
"max-concurrent-downloads": 10,
"storage-driver": "overlay2",
"graph": "/data/docker",
"log-driver": "json-file",
"log-level": "warn",
"log-opts": {
"max-size": "10m",
"max-file": "3"
}
}
-
重启docker
systemctl restart docker
-
查看是否更改为国内的镜像仓库,使用
docker info
本文来自博客园,作者:弩哥++,转载请注明原文链接:https://www.cnblogs.com/bangbangzoutianya/p/15644975.html