Skip to content

**docker compose** unavailable despite plugin being installed via mise #3

@close2infinity

Description

@close2infinity

docker compose unavailable despite plugin being installed via mise

 When `docker-cli` and `docker-compose` (as a CLI plugin) are both installed via mise/aqua,                                                                                                                                                                                                                                        
 `docker compose` fails with `unknown command: docker compose` even though the plugin binary exists.                                                                                                                                                                                                                               
                                                                                                                                                                                                                                                                                                                                   
 ### Root cause                                                                                                                                                                                                                                                                                                                    
                                                                                                                                                                                                                                                                                                                                   
 The Docker CLI discovers plugins by looking in specific directories:                                                                                                                                                                                                                                                              
                                                                                                                                                                                                                                                                                                                                   
 - `~/.docker/cli-plugins/`                                                                                                                                                                                                                                                                                                        
 - `/usr/local/lib/docker/cli-plugins/`                                                                                                                                                                                                                                                                                            
                                                                                                                                                                                                                                                                                                                                   
 When mise installs `aqua-docker-compose`, it places the binary at:                                                                                                                                                                                                                                                                
                                                                                                                                                                                                                                                                                                                                   
                                                                                                                                                                                                                                                                                                                                   
 ~/.local/share/mise/installs/aqua-docker-compose/<version>/docker-cli-plugin-docker-compose                                                                                                                                                                                                                                       
                                                                                                                                                                                                                                                                                                                                   
                                                                                                                                                                                                                                                                                                                                   
 but does **not** symlink it into either of the directories the Docker CLI searches.                                                                                                                                                                                                                                               
 As a result, `docker compose` is silently unavailable at runtime.                                                                                                                                                                                                                                                                 
                                                                                                                                                                                                                                                                                                                                   
 The fix is to manually symlink the binary:                                                                                                                                                                                                                                                                                        
                                                                                                                                                                                                                                                                                                                                   
 ```bash                                                                                                                                                                                                                                                                                                                           
 mkdir -p ~/.docker/cli-plugins                                                                                                                                                                                                                                                                                                    
 ln -sf ~/.local/share/mise/installs/aqua-docker-compose/<version>/docker-cli-plugin-docker-compose \                                                                                                                                                                                                                              
        ~/.docker/cli-plugins/docker-compose                                                                                                                                                                                                                                                                                       
                                                                                                                                                                                                                                                                                                                                   
 Proposed solutions                                                                                                                                                                                                                                                                                                                
                                                                                                                                                                                                                                                                                                                                   
 (a) Hook script — Add a mise hook (e.g. postinstall or an env-level activation script)                                                                                                                                                                                                                                            
 that automatically creates the symlink after aqua-docker-compose is installed.                                                                                                                                                                                                                                                    
 This would make the setup fully automatic for all contributors.                                                                                                                                                                                                                                                                   
                                                                                                                                                                                                                                                                                                                                   
 (b) README documentation — If a hook is not feasible, document the manual step in the                                                                                                                                                                                                                                             
 project README under a "Prerequisites" or "Getting started" section, so contributors know                                                                                                                                                                                                                                         
 they need to run the symlink command after mise install.                                            

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions