Skip to content

DOC: Environment variables in build command #1355

Open
@sbalian

Description

@sbalian

Is there a way to pass an environment variable to the build command? This is to avoid putting secrets in the JSON config.

For example, USER and PASSWORD in ...

    "build_command": [
        ...
        "python -m poetry config http-basic.private-repo $USER $PASSWORD",
        ...
    ]

Edit: with poetry, I solved my issue using:

export POETRY_HTTP_BASIC_MY_REPOSITORY_USERNAME=user
export POETRY_HTTP_BASIC_MY_REPOSITORY_PASSWORD=secret

This way, there is no need to enter the username and password into the JSON file.

Doc here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationTriaged as a documentation issuequestionTriaged as a question, not requiring action after answering

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions