I am trying to install 'docker compose' plugin on 'Mac apple silicon' machine. My org doesn't allow 'Docker Desktop' so we use 'colima' instead. There is no official documentation to install the 'compose' plugin on mac without 'docker desktop'.
The links and instrutions for 'Compose Apple Binary' that that I have extracted on various blogs and 'chat gpt' are giving 404.
Please help in installing the 'docker compose' plugin or standalone on 'Mac apple silicon' without 'docker desktop'
Here's how you do it.
If you can use Homebrew, do
brew install docker-compose
and pay heed to the notes after the installer runs. They tell you to add
"cliPluginsExtraDirs": [
"/opt/homebrew/lib/docker/cli-plugins"
]
to your ~/.docker/config.json file.
I don't know if Homebrew also installs Credentials Helper with Compose, so you might have to do:
brew install docker-credential-helper
If you can't use Homebrew, I think you'll have to do the following.
Install Credentials Helper using Docker's instructions here.
Go into ~/.docker/config.json and make sure the value for credsStore is osxkeychain. My file looks like:
{
"auths": {},
"credsStore": "osxkeychain",
"currentContext": "colima",
"plugins": {
"debug": {
"hooks": "exec"
},
"scout": {
"hooks": "pull,buildx build"
}
},
"features": {
"hooks": "true"
}
}
Download latest Docker Compose from here for your architecture (aarch64 for Apple Silicon): https://github.com/docker/compose/releases/latest
Copy the executable to /usr/local/bin, naming it docker-compose.
From there, make sure it's executable:
sudo chmod +x docker-compose
Clear Apple's scareware:
sudo xattr -d com.apple.quarantine docker-compose
As in the Homebrew case, add
"cliPluginsExtraDirs": [
"/opt/homebrew/lib/docker/cli-plugins"
]
to your ~/.docker/config.json file.
Open a new terminal session and try
docker compose version
If that doesn't work, try
docker-compose version
If that works, the cliPluginsExtraDirs entry in the config.json file isn't working.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With