Azure Monitor setup problem


Can someone help me with azure monitor? I do not know where I am failing.
I used the walkthrough but in step 5 I didn’t add the user (what user?).
My part of the code:

export let options = {
    ext: {
        loadimpact: {
            apm: [
                    provider: "azuremonitor",
                    tenantId: "directory/tenant id from registered app",
                    clientId: "application/client id from registered app",
                    clientSecret: "client secret value from registered app",
                    azureRegion: "westeurope",
                    subscriptionId: "subscription id",
                    resourceGroupName: "scalability",
                    insightsAppName: "k6-insights",
                    metrics: ["http_req_sending", "custom_metric"],
                    includeDefaultMetrics: true,
                    includeTestRunId: false

How to debug it? I am running the test locally for now. I do not see any logs in my log analytics workspace and in my app insights.

Do I have to change my run command somehow?


We discussed the issue privately on k6 Slack and this is the result:

The Azure Monitor integration is part of the Cloud APM feature, which only works if the script is run on the Cloud or using k6 cloud CLI command, therefore they’re not supported if one uses them with k6 run CLI command.
On the contrary, there are many integrations supported by k6 CLI itself, which only work if run using k6 run CLI command and some minor setup on the test machine.