Skip to content

Commit 1b854f1

Browse files
committed
fix issue using azure cli auth using multiple tenants
Signed-off-by: Markus Blaschke <[email protected]>
1 parent 9857c1b commit 1b854f1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

azuresdk/azidentity/credential.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ func NewAzDefaultCredential(clientOptions *azcore.ClientOptions) (azcore.TokenCr
7272
}
7373

7474
func NewAzCliCredential() (azcore.TokenCredential, error) {
75-
opts := azidentity.AzureCLICredentialOptions{}
75+
opts := azidentity.AzureCLICredentialOptions{
76+
AdditionallyAllowedTenants: []string{"*"},
77+
}
7678
return azidentity.NewAzureCLICredential(&opts)
7779
}

0 commit comments

Comments
 (0)