Skip to content

Support reading environment variable values from file paths (for docker secrets) #136

@zylxpl

Description

@zylxpl

Hi, thanks for the great project!

I'd like to request support for loading environment variable values from files, following a common pattern used in Docker environments—especially with secrets mounted at /run/secrets/.

The idea is to allow specifying variables like this:

AUTOKUMA__KUMA__PASSWORD_FILE=/run/secrets/kuma_password

Instead of directly setting the value in an environment variable:

AUTOKUMA__KUMA__PASSWORD_FILE=@kuma_password

Many applications (e.g., Docker official images) support this *_FILE convention by checking if a variable like VARIABLE_FILE exists, and if so, reading the contents of the specified file and using that as the value for VARIABLE.

This makes it easier and safer to handle sensitive data like API keys, credentials, etc., when deploying in containerized environments.

Would you consider adding support for this pattern?

Thanks again!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions