Skip to content

cli/compose: keep external when merging secret name overlays - #7266

Open
locker95 wants to merge 1 commit into
docker:masterfrom
locker95:fix/stack-secrets-merge-external
Open

cli/compose: keep external when merging secret name overlays#7266
locker95 wants to merge 1 commit into
docker:masterfrom
locker95:fix/stack-secrets-merge-external

Conversation

@locker95

@locker95 locker95 commented Sep 1, 2026

Copy link
Copy Markdown

Fixes #7264

docker stack config was dropping external: true when a later compose file only set the secret name. docker compose config already keeps both.

The map merge replaced the whole secret, and an empty file got filled in as the working directory. Field-merge the secret/config entries instead.

stack config replaced the whole secret/config entry, so a later file
that only set name dropped external: true. Merge fields instead, and
don't treat an omitted file as the working directory.

Signed-off-by: Dean Chen <862469039@qq.com>
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.

Unclear "secrets" merging behavior in "docker stack"

1 participant