Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Docker-Compose not installed with Docker Desktop

I installed Docker Desktop v4.12.0 on windows 10 which installed docker v20.10.17.

I am trying to run docker-compose pull but get the response docker: 'compose' is not a docker command. I've tried reinstalling Docker Desktop but I still get the same error.

docker-compose --version and docker compose --version both return the same error message.

I'm new to docker and not sure if I've done something incorrectly. Any help would be greatly appreciated!

like image 311
alexyoe Avatar asked Sep 08 '26 06:09

alexyoe


1 Answers

This can happen when we have older files laying around in windows path.

Try this:

where docker

or

where docker-compose

If you have multiple paths, maybe one of them is very old. In my case, I had to delete docker.exe and dockerd.exe in the root of c:\Program Files\Docker. The new files should be in the resources\bin folder.

If you are having difficulties running cmd "where" in Windows/Powershell, try this way:

PS C:\Users\canoas> where.exe docker
C:\Program Files\Rancher Desktop\resources\resources\win32\bin\docker.exe
C:\Program Files\Rancher Desktop\resources\resources\linux\bin\docker
PS C:\Users\canoas> where.exe docker-compose
C:\Program Files\Rancher Desktop\resources\resources\win32\bin\docker-compose.exe
C:\Program Files\Rancher Desktop\resources\resources\linux\bin\docker-compose
like image 147
Canoas Avatar answered Sep 11 '26 00:09

Canoas