-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Open
Description
This is previously raised by IcM 154830377: Azure CLI fails if NSG doesn't allow ARM endpoint
It should be possible to force az login to only do a tenant-level login and disable subscription finding. This is also called ARM-detached mode.
The current param --allow-no-subscriptions always queries ARM and the result depends on whether the tenant has subscriptions. The result is unpredictable for the client:
Does the tenant have subscriptions?
- ✔ -> build subscription-level accounts
- ❌ -> build a tenant-level account
Allowing disabling subscription finding is helpful in these scenarios:
- As in the IcM, if ARM endpoint (https://management.azure.com/ in public AzureCloud) is blocked by an NSG,
az loginfails. However, it shouldn't, as customer should still be able to useazto manage data-plane services like Storage, Microsoft Graph... - A custom cloud may not have ARM endpoint, thus causing
az loginto fail
Reactions are currently unavailable