Skip to content

[RFC] Add dynaconf get #650

@icaromedeiros

Description

@icaromedeiros

I'm trying to use dynaconf to fill envvars used outside pure Python context such as shell scripts or Docker builds.

PIP_EXTRA_INDEX_URL="https://<pip_user>:<pip_pwd>@pkgs.dev.azure.com..."

I'd like to get <pwd> value from a variable stored in .secrets.toml file

For the <pwd> it'd be good to have something like dynaconf get pip_pwd so the line above could be as simple as

PIP_EXTRA_INDEX_URL="https://$(dynaconf get pip_user):$(dynaconf get pip_pwd)@pkgs.dev.azure.com..."

Currently I'm using

PIP_EXTRA_INDEX_URL="https://<pip_user>:$(python -c 'from config import settings; print(settings.pip_pwd)')@pkgs.dev.azure.com..."

which seems obscure, verbose and indirect, i.e. not managed by dynaconf.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Not a BugNot a Problem, expected behaviorRFC

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions