ubuntu系统,修改/etc/docker/daemon.json
,修改如下。
{
builder: {
gc: {
defaultKeepStorage: 20GB,
enabled: true
}
},
experimental: false,
features: {
buildkit: true
},
registry-mirrors: [
"https://docker.mirrors.ustc.edu.cn",
"https://mirror.baidubce.com",
"https://docker.m.daocloud.io",
"https://mirror.ccs.tencentyun.com",
"https://docker.nju.edu.cn",
"https://docker.mirrors.sjtug.sjtu.edu.cn",
"https://mirror.gcr.io",
"https://docker.registry.cyou",
"https://docker-cf.registry.cyou",
"https://dockercf.jsdelivr.fyi",
"https://docker.jsdelivr.fyi",
"https://dockertest.jsdelivr.fyi",
"https://mirror.aliyuncs.com",
"https://dockerproxy.com
]
}
【修改后需要重启】:
sudo systemctl daemon-reload
sudo systemctl restart docker
sudo systemctl status docker
sudo docker info
【其他】 也可以直接查看 GitHub 仓库:docker-practice/docker-registry-cn-mirror-test 的 Github Action 执行结果。
文章评论