没有与 windows/amd64 10.0.18362 匹配的清单列表条目
时间:2024-03-18
浏览:292
作者:佚名
**文章首段摘要** 在使用 Docker 构建镜像时,遇到了 "no matching manifest for windows/amd64 10.0.18362 in the manifest list entries" 的错误,原因是 Docker 无法在 Windows 系统上运行带 -alpine 标记的 Linux 容器。
问题内容
我刚刚开始使用 docker。 我安装了 windows 版本的 docker,并按照 https://hub.docker.com/?overlay=onboarding 中给出的一些基本步骤进行操作。
无法构建 docker 文件。
我刚刚从中克隆了一个 git 存储库 作者:
$ git clone https://github.com/docker/doodle.git
然后尝试构建docker
$ cd doodle\cheers2019 ; $ docker build -t myrepo/cheers2019 .
我在命令行上收到响应:
sending build context to docker daemon 13.31kb step 1/9 : from golang:1.11-alpine as builder 1.11-alpine: pulling from library/golang no matching manifest for windows/amd64 10.0.18362 in the manifest list entries
dockerfile 有
FROM golang:1.11-alpine AS builder RUN apk add --no-cache git RUN go get github.com/pdevine/go-asciisprite WORKDIR /project COPY cheers.go . RUN CGO_ENABLED=0 GOOS=linux go build -a -ldflags '-extldflags "-static"' -o cheers cheers.go FROM scratch COPY --from=builder /project/cheers /cheers ENTRYPOINT ["/cheers"]
我的电脑规格: windows 10 - amd ryzen5 处理器
amd 处理器有问题吗?请建议我一些方法来解决这个问题。
解决方案
接下来是 docker/doodle issue 9,最后是 includes a workaround。
还有更简单的建议:
另一种方法是转到 Docker 桌面并选择Switch to Linux Containers。
问题是由于标记的 -alpine 部分造成的,不幸的是没有可在 Windows 上运行的 alpine Linux 容器。
好了,本文到此结束,带大家了解了《没有与 windows/amd64 10.0.18362 匹配的清单列表条目》,希望本文对你有所帮助!关注golang学习网公众号,给大家分享更多Golang知识!
本文内容来源于互联网,如有侵权请联系删除。
近期热门
11.18
11.15
站内热门
最新文章
11.20
11.20
11.20
11.20
热门专题
