1.编辑/etc/docker
目录下的文件daemon.json
cd /etc/docker sudo vim daemon.json
修改文件daemon.json
中的内容为:
{ "registry-mirrors": [ "https://dockerproxy.com", "https://hub-mirror.c.163.com", "https://mirror.baidubce.com", "https://ccr.ccs.tencentyun.com" ] }
2. 重新载入文件daemon.json
systemctl daemon-reload
3. 重启docker服务
systemctl restart docker.service
4. 检查是否更新国内源成功
docker info
终端显示:
Registry Mirrors: https://dockerproxy.com/ https://hub-mirror.c.163.com/ https://mirror.baidubce.com/ https://ccr.ccs.tencentyun.com/
标签:daemon,json,开源,https,mirror,镜像,docker,com From: https://www.cnblogs.com/zjdxr-up/p/18390222