Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

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

Open
Labels
area/composeRelates to docker-compose.yml spec or docker-compose binary
@quentinsf

Description

Is this a docs issue?

  • My issue is about the documentation content or website

Type of issue

Information is incorrect

Description

It would be nice to have a note in the documentation to the effect that setting secrets from environment variables. eg:

secrets:
 borg_backup_ssh_key:
 environment: "BORG_BACKUP_SSH_KEY"

work when the compose file is used for docker compose, but NOT when it is used for docker stack deploy. It appears that a file source is needed then.

Location

https://docs.docker.com/reference/compose-file/secrets/

Suggestion

It would be wonderful if the code could be fixed to allow this, but in the meantime, a note to the effect that the 'environment' clause only works in certain... ahem... environments would be very helpful.

Metadata

Metadata

Assignees

No one assigned

    Labels

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

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /