最佳答案
我是相当新的多克,并试图建立一个简单的 HTML 多克图像,但我有这个错误消息,说
未能用前端 Dockerfile.v0解决: 未能读取 Dockerfile: open/var/lib/docker/tmp/buildkit-mount 602954594/Dockerfile: 没有这样的文件或目录
我的文件夹目录如下:
C:\Users\hailey\Desktop\GitTest
|- Dockerfile.txt
|- README.md
|- testHelloWorld.html
Inside of the Dockerfile, I have
FROM ubuntu
WORKDIR C/Users/hailey/Desktop/GitTest
COPY testHelloWorld.html .
EXPOSE 8080
CMD ["html","testHelloWorld.html"]
I did my command docker build .
inside of the directory C: 用户 Hailey 桌面 GitTest and then got:
[+] Building 0.1s (2/2) FINISHED
=> [internal] load build definition from Dockerfile
=> => transferring dockerfile: 2B
=> [internal] load .dockerignore
=> => transferring context: 2B
failed to solve with frontend dockerfile.v0: failed to read dockerfile: open /var/lib/docker/tmp/buildkit-mount602954594/Dockerfile: no such file or directory
What did I do wrong?