Skip to content

compose: note that secrets require Linux containers#25541

Open
mickey-mikey wants to merge 2 commits into
docker:mainfrom
mickey-mikey:compose-secrets-windows-note
Open

compose: note that secrets require Linux containers#25541
mickey-mikey wants to merge 2 commits into
docker:mainfrom
mickey-mikey:compose-secrets-windows-note

Conversation

@mickey-mikey

@mickey-mikey mickey-mikey commented Jul 11, 2026

Copy link
Copy Markdown

Description

Adds a NOTE callout to the Compose secrets guide stating that secrets are supported on Linux containers only, with the reason.

The page states secrets are delivered as a bind mount at /run/secrets/<secret_name>, with no platform caveat. On Windows containers this fails at container creation:

invalid mount config for type "bind": source path must be a directory

Windows containers can't bind-mount a single file, only directories — a platform limitation confirmed by maintainers in moby/moby#37120 and docker/cli#2055. Because Compose secrets are single-file bind mounts, they can't work on Windows containers.

Tested on a Windows Server 2025 container (mcr.microsoft.com/windows/server:ltsc2025), Hyper-V isolation, Docker 29.6.1, Compose v2.

Fixes #25540

Related issues or tickets

Reviews

  • Technical review
  • Editorial review

@netlify

netlify Bot commented Jul 11, 2026

Copy link
Copy Markdown

Deploy Preview for docsdocker ready!

Name Link
🔨 Latest commit c9059ac
🔍 Latest deploy log https://app.netlify.com/projects/docsdocker/deploys/6a51f17219d82d00082e1df6
😎 Deploy Preview https://deploy-preview-25541--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.

@github-actions github-actions Bot added the area/compose Relates to docker-compose.yml spec or docker-compose binary label Jul 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/compose Relates to docker-compose.yml spec or docker-compose binary

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Compose secrets page: file-based secrets don't work on Windows containers (no caveat noted)

1 participant