I am trying to copy content of a directory while creating the docker image in the Dockerfile but while copying its giving me error-
COPY failed: stat /var/lib/docker/tmp/docker-builder108255131/Users/user_1/media : no such file or directory
I have the following file in the Dockerfile-
COPY /Users/user_1/media/. /code/project_media/
The media directory is in a seperate directory level then Dockerfile.
Sorry per dockerfile documentation:
https://docs.docker.com/engine/reference/builder/#copy
I usually will have a script for building the docker, and in that script will copy the files need for the
COPY
command into either the same directory or sub-directory of the "context of the build" (a very confusing way of saying the same directory as the dockerfile is in)