-
-
Notifications
You must be signed in to change notification settings - Fork 128
[BUG] selecting compose.override.yaml in the editor ignores the main compose.yaml #884
Description
Description
Dockhand doesn't take the main compose.yaml into account if compose.override.yaml is being used as the primary file. This is very unfortunate because there are a number of docker compose distributions provided by service developers where the operator is expected to primarily edit compose.override.yaml, e.g. https://github.com/zulip/docker-zulip.
To fix this Dockhand should run Command: docker compose -p test-override -f /mnt/user/apps/test-override/compose.yaml -f /mnt/user/apps/test-override/compose.override.yaml up -d --remove-orphans --force-recreate as it does when compose.yaml is selected in the same directory.
A somewhat more comprehensive fix would be to improve support of switching between main and override compose files, maybe have a list of compose files passed to -f as a generic solution and allow the user to quickly switch between them in the UI.
P.S. There is another bug I discovered related to compose.override.yaml
Switching between compose.yaml and compose.override.yaml results in the content override prompt:
instead of switching the file. I believe this shows that Dockhand assumes a single compose file in the UI, and compose.override.yaml support is inconsistent.
P.P.S. This is not the same as #367 where seemingly the main compose file is used, but it is not very clear.
Steps to reproduce
- Create
compose.yaml
# cat compose.yaml
services:
app:
image: nginx:alpine
restart: unless-stopped
app2:
image: nginx:alpine
restart: unless-stopped
- Create
compose.override.yaml
# cat compose.override.yaml
services:
app2:
image: nicolaka/netshoot
command: sleep 1000
- Open
compose.override.yamlin Dockhand:
- Press
Save and redeploy, this runsCommand: docker compose -p test-override -f /mnt/user/apps/test-override/compose.override.yaml up -d --remove-orphans --force-recreate - Observe only the
app2from override running.
Logs
Current log:
2026-04-05T15:31:19.141Z [Stack:test-override] ----------------------------------------
2026-04-05T15:31:19.141Z [Stack:test-override] EXECUTE LOCAL COMPOSE
2026-04-05T15:31:19.141Z [Stack:test-override] ----------------------------------------
2026-04-05T15:31:19.141Z [Stack:test-override] Operation: up
2026-04-05T15:31:19.141Z [Stack:test-override] Command: docker compose -p test-override -f /mnt/user/apps/test-override/compose.override.yaml up -d --remove-orphans --force-recreate
2026-04-05T15:31:19.141Z [Stack:test-override] Working directory: /mnt/user/apps/test-override
2026-04-05T15:31:19.141Z [Stack:test-override] Compose file: /mnt/user/apps/test-override/compose.override.yaml
2026-04-05T15:31:19.141Z [Stack:test-override] DOCKER_HOST: (local socket)
2026-04-05T15:31:19.141Z [Stack:test-override] DOCKER_API_VERSION: (not set - native negotiation)
2026-04-05T15:31:19.141Z [Stack:test-override] Force recreate: true
2026-04-05T15:31:19.141Z [Stack:test-override] Remove volumes: false
2026-04-05T15:31:19.141Z [Stack:test-override] Service name: (all services)
2026-04-05T15:31:19.141Z [Stack:test-override] Env vars count: 0
2026-04-05T15:31:19.141Z [Stack:test-override] Spawning docker compose process...
2026-04-05T15:31:19.907Z [Stack:test-override] ----------------------------------------
2026-04-05T15:31:19.907Z [Stack:test-override] COMPOSE PROCESS COMPLETE
2026-04-05T15:31:19.907Z [Stack:test-override] ----------------------------------------
Expected log:
2026-04-05T15:50:24.868Z [Stack:test-override] ----------------------------------------
2026-04-05T15:50:24.868Z [Stack:test-override] EXECUTE LOCAL COMPOSE
2026-04-05T15:50:24.868Z [Stack:test-override] ----------------------------------------
2026-04-05T15:50:24.868Z [Stack:test-override] Operation: up
2026-04-05T15:50:24.868Z [Stack:test-override] Command: docker compose -p test-override -f /mnt/user/apps/test-override/compose.yaml -f /mnt/user/apps/test-override/compose.override.yaml up -d --remove-orphans --force-recreate
2026-04-05T15:50:24.868Z [Stack:test-override] Working directory: /mnt/user/apps/test-override
2026-04-05T15:50:24.868Z [Stack:test-override] Compose file: /mnt/user/apps/test-override/compose.yaml
2026-04-05T15:50:24.868Z [Stack:test-override] DOCKER_HOST: (local socket)
2026-04-05T15:50:24.868Z [Stack:test-override] DOCKER_API_VERSION: (not set - native negotiation)
2026-04-05T15:50:24.868Z [Stack:test-override] Force recreate: true
2026-04-05T15:50:24.868Z [Stack:test-override] Remove volumes: false
2026-04-05T15:50:24.868Z [Stack:test-override] Service name: (all services)
2026-04-05T15:50:24.868Z [Stack:test-override] Env vars count: 0
2026-04-05T15:50:24.868Z [Stack:test-override] Spawning docker compose process...
2026-04-05T15:50:26.331Z [Stack:test-override] ----------------------------------------
2026-04-05T15:50:26.331Z [Stack:test-override] COMPOSE PROCESS COMPLETE
2026-04-05T15:50:26.331Z [Stack:test-override] ----------------------------------------Browser logs
Dockhand version
1.0.24
Hawser version (if used)
No response
Connection mode
socket
Please confirm the following
- I have already searched for relevant existing issues and discussions before opening this report.
- I have updated the title field above with a concise description.