Repository navigation
feat(compose): multiple compose files and profiles - #26
Merged
Merged
Conversation
- docker compose -f a.yml -f b.yml: every -f is kept (the parser now records all values of a flag) and the files are merged in order at the YAML tree level. Maps merge key by key, command and entrypoint are replaced, other lists accumulate without repeats. - Without -f: COMPOSE_FILE (colon-separated), else compose.yaml or docker-compose.yml, plus the matching .override file when present. - --profile (repeatable) and COMPOSE_PROFILES enable services that declare profiles; other profiled services are left out. - Parser: DockerCommand.values(_:) returns every occurrence of a flag.
This was referenced Oct 21, 2026
Keep both the compose file and profile helpers and the registry login helpers.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
docker compose -f a.yml -f b.yml: all-ffiles are merged in order (maps key by key,command/entrypointreplaced, lists accumulate without repeats).COMPOSE_FILE, thencompose.yaml/docker-compose.yml, plus the matching.overridefile.--profile(repeatable) andCOMPOSE_PROFILESenable profiled services.DockerCommand.values(_:)exposes every value of a repeatable flag.Test plan
swift test:ComposeMultiFileTests(3 tests) and the full suite passNot in this PR:
scale,configsmounts, and healthcheck/deploy behaviour (next steps for item 3).