docker-compose -f /my/path/docker-compose.yml - No such file or directory
Hi guys !
When doing a docker-compose -f /a/b/c/docker-compose.yml pull from /a -> it works.
When doing a docker-compose -f /a/b/c/docker-compose.yml pull from /a/foo/bar -> it does not work:
ERROR: .IOError: [Errno 2] No such file or directory: '/a/b/c/docker-compose.yml'
Didn't investigate more on this problem.
$ docker-compose version
docker-compose version 1.8.0, build f3628c7
docker-py version: 1.9.0
CPython version: 2.7.12
OpenSSL version: OpenSSL 1.0.2h 3 May 2016
Having the same probleme here. Any news on this?
+1, met same issue on 1.8.0 version
Same issue.
Docker version: 1.12.5 docker-compose version: 1.9.0
How to reproduce:
cd /home/userBBB/
docker-compose -f /home/userAAA/subdir/test.yml up -d
# ERROR: .IOError: [Errno 2] No such file or directory: '/home/userAAA/subdir/test.yml'
cd /home/userAAA/
docker-compose -f /home/userAAA/subdir/test.yml up -d
# it works
It is NOT a premissions problem on /home/userAAA/subdir/test.yml or any part of the path (i checked this).
Same problem here, v1.8.0 build f3628c7.
Same problem here, I saw it when I added a systemctl service and it fails to run in system boot with this message.
Same problem, it's really weird. I've no clue why that's not working.
Version 17.11.0-ce-rc3-mac38 (20152)
Channel: edge
a091b4ad0a
Same problem here... Someone solved this? Pliz share :(
i'm on windows and that's my docker version:
$ docker-compose version
docker-compose version 1.16.1, build 6d1ac219
docker-py version: 2.5.1
CPython version: 2.7.13
OpenSSL version: OpenSSL 1.0.2j 26 Sep 2016
My problem seems to be an issue using many files...
i'm not that good in docker and i really don't know how to solve this. Even because i'm using laradock and it has a lot of things on it that i don't understand.
Any way, when i remove the bold text, it runs.
COMPOSE_FILE=docker-compose.yml:docker-compose.dev.yml
But it feels wrong. I'm going to downgrade docker version tomorrow and see how it works.
Getting the same thing as @rafadpedrosa, thanks for the solution!
Don't really know docker yet though so not sure if this is an issue.
@samber @coolcow trying to reproduce but can't. Can you elaborate test steps pls?
@coolcow I can't see what is different between these two
cd /home/userBBB/
docker-compose -f /home/userAAA/subdir/test.yml up -d
# ERROR: .IOError: [Errno 2] No such file or directory: '/home/userAAA/subdir/test.yml'
cd /home/userAAA/
docker-compose -f /home/userAAA/subdir/test.yml up -d
# it works
Was able to reproduce. Works for me.
Ubuntu Linux, docker-compose version 1.21.0-rc1, build 1d32980 docker-py version: 3.2.1 CPython version: 3.6.4 OpenSSL version: OpenSSL 1.0.1t 3 May 2016
m@m:~/userBBB$ docker-compose -f /home/m/userAAA/subdir/docker-compose.yml up -d
Starting subdir_web_1 ... done
Starting subdir_redis_1 ... done
@samber Hey, could we close this issue? It seems it has been resolved. Works for me. Can you try again and then close it?
@Mat001 Cannot reproduce this bug with docker-compose 1.20.1.
Thanks to whoever fixed that ;)
I have the same problem
docker-compose version 1.22.0, build f46880fe docker-py version: 3.4.1 CPython version: 3.6.6 OpenSSL version: OpenSSL 1.1.0f 25 May 2017
(18-10-05 0:56:06) <0> [/] ocker-compose -f /tmp/tmpfRtJlW/docker-compose.yaml up --build --abort-on-container-exit ERROR: .FileNotFoundError: [Errno 2] No such file or directory: '/tmp/tmpfRtJlW/docker-compose.yaml'
(18-10-05 1:03:58) <0> [/tmp] docker-compose -f /tmp/tmpfRtJlW/docker-compose.yaml up --build --abort-on-container-exit Working!
It works for me (OSX, 1.22).
@samber Thanks for confirming, do you think that's because I use an old docker? Client: Version: 1.12.6 API version: 1.24 Go version: go1.6.3 Git commit: 7392c3b/1.12.6 Built: Thu Jan 26 09:26:48 2017 OS/Arch: linux/amd64
Server: Version: 1.12.6 API version: 1.24 Go version: go1.6.3 Git commit: 7392c3b/1.12.6 Built: Thu Jan 26 09:26:48 2017 OS/Arch: linux/amd64
Yes, maybe...
But I think this issue was for docker-compose, not docker engine.
Anyway, using an old docker-compose version with a recent docker engine does not guaranty that everything is working well! At that time, Docker retro-compatibility was not very nice :-(.
My pc docker compose current versionis 1.22.0 how can i downgrade it to 1.20.0 where i wont reproduce that error?
Hi guys I'm getting this error while giving command can someone help in this...
THanks in advance
Any follow up on this? I've spend a lot of time with this lately, but it seems like the -f option to docker-compose is rather useless, or at least misleading. As is the error message.
It seems natural to have one docker-compose file in a central location that starts multiple containers from multiple directories (each in different repositories).
Not sure if my problem is actually related to this Issue or not because the error is extremely unhelpful.