docker制作镜像提示unable to prepare context: unable to evaluate symlinks in Docker

linux 创建docker 镜像时提示如下:

[root@VM_0_10_centos docker]# docker build -t jdk8  --rm=true .
unable to prepare context: unable to evaluate symlinks in Dockerfile path:
 lstat /docker/Dockerfile: no such file or directory

开始以为是自己的路径错误,检查各种地址。
最终发现是Dockerfile 名字错误,我定义的是DockerFile,所以要么把文件名改成Dockerfile,要么执行下面的命令
docker build -t docker-whale -f DockerFiler .

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章