Skip to content

Conversation

veyselsahin
Copy link

On Ubuntu 24.04 with the docker.io package, docker compose (Compose v2
plugin) is not installed by default, but the legacy docker-compose
binary is available and works.

The current install.sh assumes that if docker compose version fails,
Compose is not installed at all, and unconditionally tries to install
the docker-compose-plugin. This can fail in two ways:

  • Ubuntu repos may not have docker-compose-plugin.
  • Adding Docker's apt repo causes docker-buildx-plugin to conflict with
    Ubuntu's docker-buildx from docker.io.

Even if the install succeeds, final user instructions always print
docker compose ..., which fails on systems that only have the legacy
binary.

Fix:

  • Introduce a sudo-aware COMPOSE_CMD that prefers $DOCKER_CMD compose
    but falls back to docker-compose if available.
  • Use $COMPOSE_CMD for the plugin check and in final instructions.

This avoids unnecessary installs, prevents package conflicts, and makes
the installer work on both Docker's official packages and Ubuntu's
docker.io defaults.

@lukemarsden
Copy link
Collaborator

Thanks for the PR! I left one comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants