相关疑难解决方法(0)

Azure Cli 如何为 webapp 启用 Application Insights

考虑以下代码。它创建一个应用程序洞察,然后它检索检测密钥并将其分配给我的 web 应用程序。

    az monitor app-insights component create -g $resourceGroup --app $webapp --application-type web --kind web --tags $defaultTags
    
    $instrumentationKey = az monitor app-insights component show -g $resourceGroup -a $webapp --query 'instrumentationKey' -o tsv
    az webapp config appsettings set -g $resourceGroup -n $webapp --settings APPINSIGHTS_INSTRUMENTATIONKEY=$instrumentationKey APPLICATIONINSIGHTS_CONNECTION_STRING=InstrumentationKey=$instrumentationKey
Run Code Online (Sandbox Code Playgroud)

但是,这不会打开此屏幕截图中所示的 web 应用程序的应用程序洞察力。我不知道如何从 azure cli 打开它。

在此处输入图片说明

azure azure-application-insights azure-cli azure-webapps

4
推荐指数
2
解决办法
1246
查看次数