Skip to content

Az CLI ignores options if environment variables are set #27

@manekinekko

Description

@manekinekko

Describe the bug

When creating a storage instance, the az CLI will check if the following environment variables are set, if so, it will use them and ignore the options passed to the CLI:

  • AZURE_STORAGE_CONNECTION_STRING
  • AZURE_STORAGE_ACCOUNT
  • AZURE_STORAGE_ACCESS_KEY

To Reproduce

Set any of these environment variables in your terminal before usign hexa:

AZURE_STORAGE_ACCOUNT="fake" hexa init --just=storage

Expected behavior

Hexa (and the az cli) should ignore the user-defined env variables and use the values passed through the CLI options.

Additional context

Other Azure services might be affected by a similar bug (needs to investigate).

cc @sinedied who reported this issue.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions