问题描述
构建镜像的时候pull失败,用到国内镜像源,阿里和腾讯云都试过不行
让你拉个镜像,不是刮风就是下雨
ERROR: failed to solve: eclipse-temurin:8-jre: failed to resolve source metadata for docker.io/library/eclipse-temurin:8-jre: failed to do request: Head "https://mirror.ccs.tencentyun.com/v2/library/eclipse-temurin/manifests/8-jre?ns=docker.io": dial tcp: lookup mirror.ccs.tencentyun.com on 8.8.8.8:53: no such host
ERROR: failed to solve: eclipse-temurin:8-jre: failed to resolve source metadata for docker.io/library/eclipse-temurin:8-jre: unexpected status from HEAD request to https://kp2d3yik.mirror.aliyuncs.com/v2/library/eclipse-temurin/manifests/8-jre?ns=docker.io: 403 Forbidden
解决方法
复制如下内容到 /etc/docker/daemon.json中
{
"registry-mirrors": [
"https://docker.m.daocloud.io",
"https://noohub.ru",
"https://huecker.io",
"https://dockerhub.timeweb.cloud",
"https://docker.rainbond.cc"
]
}
systemctl restart docker
docker info #查看是否配置成功