Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

docker-compose ERROR: .FileNotFoundError: [Errno 2] No such file or directory:

So when i run the command,

docker-compose -f config/somefile.yml up -d

I get the following error: ERROR: .FileNotFoundError: [Errno 2] No such file or directory: ./config/somefile.yml

I tried giving the full path to the yml file, but the error is the same.

However, when i create a dulicate file with the name docker-compose.yml (by using, script: cp somefile.yml docker-compose.yml) and then i run

docker-compose up

It runs fine. It just cannot run any other file than the default one. Ive searched a lot of places and could not find any solution. Any help will be greatly appreciated. Thanks

Docker-compose: 1.22 O.S: Ubuntu 14.4

like image 772
Umair Avatar asked Oct 28 '18 22:10

Umair


1 Answers

In my case, I forgot to start Docker itself.

So, check if you've started the Docker application before executing docker-compose.

like image 120
German Khokhlov Avatar answered Sep 19 '22 16:09

German Khokhlov