PyCharm can't find docker-compose
I'm trying to follow these instructions - https://www.jetbrains.com/help/pycharm/docker.html - on a Mac.
My Docker project works at the command line, and I can launch the whole thing with "docker stack deploy -c docker-compose.yml <name>"
In PyCharm, both Docker plugins are installed and active. If I type `docker-compose -v` into the Terminal window inside Pycharm, I get the version 1.18.0, although it does warn that "an older version of the docker-py package may be polluting the namespace". It then recommends a series of pip commands to fix the issue, which don't work. But, docker-compose is there, anyway.
I added a Docker > Docker-compose configuration in Pycharm and pointed it to my docker-compose.yml file. But when I click Run, it says "Cannot run program "docker-compose" (in directory <my project directory>): error=2, No such file or directory.
Can anyone advise on why this is happening, and how to fix it?
请先登录再写评论。
4 years later I have the same issue in Goland.
Edit:
Seems that a simple
`ln -sf <docker-compose-location> /usr/bin/docker-compose`
and restarting the IDE fixes it.
For some reason the IDE doesn't look for this tool in the PATH? I could run 'docker-compose' in any terminal because it was in my path, but I guess Jetbrains IDE only look at /usr/bin/... ?