Skip to content

Instantly share code, notes, and snippets.

@geekzter
Last active April 6, 2021 18:11
Show Gist options
  • Save geekzter/cfa4be6890f966c1f3e2c4aa0489736f to your computer and use it in GitHub Desktop.
Save geekzter/cfa4be6890f966c1f3e2c4aa0489736f to your computer and use it in GitHub Desktop.
Use Azure CLI to authenticate to Terraform interactively, ARM_SUBSCRIPTION_ID takes precedence
$env:ARM_SUBSCRIPTION_ID=00000000-0000-0000-0000-000000000000
$env:ARM_TENANT_ID=00000000-0000-0000-0000-000000000000
az login -t $env:ARM_TENANT_ID
az account set --subscription $env:ARM_SUBSCRIPTION_ID
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment