Is your feature request related to a problem? Please describe.
Since I would like to integrate with Managed identity, it can work well on Azure cloud, but I need to run from local to test with VSCode.
I've checked some documents, the best option without changing any code is use SharedTokenCacheCredential, but it only supports VisualStudio, not VS Code yet
Describe the solution you'd like
is any way I can us DefaultAzureCredential with azure CLI account developing locally, and no need extra code to change when deploying to Azure with managed identity? like Azure SDK for python already support?
I believe this feature is available in the latest preview version of the @azure/identity package. Please try version 1.1.0-preview.4 or higher.
cc @jonathandturner to correct me if I got the above wrong
@isaacjoe - The @azure/identity package doesn't support SharedTokenCacheCredential, yet, though we're working on adding support for it.
If you use one of the preview versions of the @azure/identity npm package, you can use DefaultAzureCredential. This will connect to Managed Identity as the chain of credentials it tries. It also comes pre-configured to connect via Azure CLI and VS Code (using the Azure Account extension), which lets you develop locally using the same code you would deploy.
Thanks @jonathandturner
@isaacjoe, Please try out the previews and share any feedback you have
@ramya-rao-a , @jonathandturner , it works perfectly, awesome!! thank you for supporting and responsive quickly
Most helpful comment
@isaacjoe - The
@azure/identitypackage doesn't support SharedTokenCacheCredential, yet, though we're working on adding support for it.If you use one of the preview versions of the
@azure/identitynpm package, you can use DefaultAzureCredential. This will connect to Managed Identity as the chain of credentials it tries. It also comes pre-configured to connect via Azure CLI and VS Code (using the Azure Account extension), which lets you develop locally using the same code you would deploy.