Describe the bug
When using az login --allow-no-subscriptions --tenant 'abcd1234-1234-1234-1234-1234abcd1234' --output none it does not honor the local configuration file.
Related command
Set the local config to not use the interactive login experience:
$ az --version
azure-cli 2.61.0
$ az config --local set core.login_experience_v2=off
Verify that local config has core.login_experience_v2 disabled and global config is unset:
$ az config get core.login_experience_v2
Configuration 'core.login_experience_v2'is not set.
$ az config get --local core.login_experience_v2
{
...
"value: "off"
}
Try to connect specifying a tenant id:
$ az login --allow-no-subscriptions --tenant 'abcd1234-1234-1234-1234-1234abcd1234' --output none
However, it prompts the user to select a subscription. If global config is set to core.login_experience_v2=off then there's no prompt.
Errors
No errors
Issue script & Debug output
Retrieving tenants and subscriptions for the selection...
[Tenant and subscription selection]
No Subscription name Subscription ID Tenant
----- --------------------------------- ------------------------------------ ---------
[1] Some sub 1231123123 Some tenant
Expected behavior
az login --allow-no-subscriptions --tenant 'abcd1234-1234-1234-1234-1234abcd1234' --output none should not prompt the user to select a subscription
Environment Summary
azure-cli 2.65.0
core 2.65.0
telemetry 1.1.0
Extensions:
account 0.2.5
automation 1.0.0b1
init 0.1.0
next 0.1.3
Dependencies:
msal 1.31.0
azure-mgmt-resource 23.1.1
Python location 'C:\Program Files\Microsoft SDKs\Azure\CLI2\python.exe'
Extensions directory 'C:\Users\danmacode\.azure\cliextensions'
Python (Windows) 3.11.8 (tags/v3.11.8:db85d51, Feb 6 2024, 22:03:32) [MSC v.1937 64 bit (AMD64)]
Additional context
No response
Describe the bug
When using
az login --allow-no-subscriptions --tenant 'abcd1234-1234-1234-1234-1234abcd1234' --output noneit does not honor the local configuration file.Related command
Set the local config to not use the interactive login experience:
$ az --version azure-cli 2.61.0 $ az config --local set core.login_experience_v2=offVerify that local config has
core.login_experience_v2disabled and global config is unset:Try to connect specifying a tenant id:
$ az login --allow-no-subscriptions --tenant 'abcd1234-1234-1234-1234-1234abcd1234' --output noneHowever, it prompts the user to select a subscription. If global config is set to
core.login_experience_v2=offthen there's no prompt.Errors
No errors
Issue script & Debug output
Expected behavior
az login --allow-no-subscriptions --tenant 'abcd1234-1234-1234-1234-1234abcd1234' --output noneshould not prompt the user to select a subscriptionEnvironment Summary
Additional context
No response