docker compose failed to solve with frontend dockerfile.v0: failed to create LLB definition: unexpected status code [manifests 18.04]: 403 Forbidden
2023-11-04 01:06 youxin 阅读(909) 评论(0) 编辑 收藏 举报使用docker build命令构建镜像报:
“failed to solve with frontend dockerfile.v0: failed to create LLB definition: unexpected status code [manifests 18.04]: 403 Forbidden”,
网上很多文章都说修改docker的配置:
出现此原因只需要设置一下docker的setting。
它发生在构建过程中,它是 buildkit 中的一个错误,考虑到 buildkit 仍然不稳定。如果您在 Mac/Windows 上使用 Docker 桌面,您可能还必须在“Docker Engine”json 配置中禁用它。 Docker 桌面 -> 设置 -> Docker 引擎 ->“features”: { buildkit: true}将"features": { buildkit: false}.
上面的做法不能解决问题。正确的做法是:
先手动拉镜像: docker pull 镜像名
然后使用docker-compose up -d 就可以了。
2024.01.20遇到另外一个错误:
ERROR resolve image config for docker.io/docker/dockerfile:experimental 30.2s
------
> resolve image config for docker.io/docker/dockerfile:experimental:
------
error: failed to solve: rpc error: code = Unknown desc = failed to solve with frontend dockerfile.v0: failed to solve with frontend gateway.v0: unexpected status code [manifests experimental]: 403 Forbidden
Fixed by forcing pull.
docker pull docker/dockerfile:experimental
解决来源:https://stackoverflow.com/questions/63813291/docker-buildkit-experimental-stopped-working