Skip to content

compose-file: note that environment source isn't supported by stack deploy#24812

Open
lacatoire wants to merge 2 commits intodocker:mainfrom
lacatoire:fix/issue-23678-secrets-environment-stack
Open

compose-file: note that environment source isn't supported by stack deploy#24812
lacatoire wants to merge 2 commits intodocker:mainfrom
lacatoire:fix/issue-23678-secrets-environment-stack

Conversation

@lacatoire
Copy link
Copy Markdown
Contributor

Adds a callout on both secrets.md and configs.md reference pages explaining that the environment source is honored by docker compose but causes docker stack deploy to fail, with file or external as the workaround.

Verified against docker/cli cli/compose/convert/compose.go where fileObjectConfig() only reads obj.File. When only environment: is set, os.ReadFile("") surfaces an error and the stack deploy fails.

Closes #23678

…eploy

docker stack deploy goes through cli/compose/convert which only reads
the file source and ignores environment. The command fails to read the
secret or config when only environment is set.

Closes docker#23678
@netlify
Copy link
Copy Markdown

netlify bot commented Apr 17, 2026

Deploy Preview for docsdocker ready!

Name Link
🔨 Latest commit e5bb928
🔍 Latest deploy log https://app.netlify.com/projects/docsdocker/deploys/69e28e056384bc00089d36ca
😎 Deploy Preview https://deploy-preview-24812--docsdocker.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

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.

Setting secrets from environment variables doesn't work in a swarm deploy

1 participant