Open
Description
Description
Background
After Installing Azure PowerShell, during the first time importing Az.Accounts, we will generate a file called AzureRmContextSettings.json
.
For the InstallationId
session in this file, we follow the rules:
- If detected
azconfig.json
generated by AzCLI Installation id, reuse it. - If not detected, randomly generate a new guid.
By doing so, we can identify the Machines calling AzCLI/ AzPS command by the installation Id.
Issue
But we have some troubles while trying reusing this id. The Installation Id cannot keep the same with AZ CLI under situations when:
-
Under case-sensitive systems, like Lunix/ MacOS.
-
User defined a
AZURE_CONFIG_DIR
while installing AzCLI (*).(*) How AzCLI generate an Installation Id:
- It first checks if the environment variable AZURE_CONFIG_DIR is set.
- If AZURE_CONFIG_DIR is not set, it defaults to ~/.azure/.
Issue script & Debug output
N/A
Environment data
N/A
Module versions
N/A
Error output
N/A