while running the docker build, it can not see any file/directory outside of the current context. so if your Dokerfile located in a directory, it will load that directory and any subdirectories of it as the current context. Placing the Dockerfile in /home is not a good idea as this will take a long time to load entire /home and all its content.
So as a solution, place Dockerfile where the SNAPSHOT is getting generated after compilation. it should work. On Sat, Oct 6, 2018 at 5:00 PM Modak, Prashant Kumar <[email protected]> wrote: > Hi Dev, > I am facing issue while trying to create docker image of Airavata project. > I have create a Dockerfile, in which i have added a COPY command, > while trying to run COPY > /home/prashant/Desktop/airavata/modules/distribution/target/apache-airavata-server-0.17-SNAPSHOT-bin.tar.gz > apache-airavata-server.tar.gz > it's giving me exception: > COPY failed: stat > /var/lib/docker/tmp/docker-builder209765050/home/prashant/Desktop/airavata/modules/distribution/target/apache-airavata-server-0.17-SNAPSHOT-bin.tar.gz: > no such file or directory > > I check for this issue online and tried multiple ways to resolve it, but > the issue still exists. > > Please advice, if anyone faced the same issue. > > Thanks and Regards. > Prashant
