Skip to content

Instantly share code, notes, and snippets.

@mysticrenji
Created December 18, 2020 04:54
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
Azure ARC - Monitoring on Worker Nodes
#To enable monitoring on the worker nodes
curl -o enable-monitoring.sh -L https://aka.ms/enable-monitoring-bash-script
subscriptionId="<subscriptionid>"
clusterName="<AzureArcName>"
resourceGroup="<ResourceGroupName>"
analyticsWorkspace="<AnalysticsWorkspaceName>"
kubeContext="<KubecontextName>"
azureArcClusterResourceId = "/subscriptions/$subscriptionId/resourceGroups/$resourceGroup/providers/Microsoft.Kubernetes/connectedClusters/$clusterName"
logAnalyticsWorkspaceResourceId="/subscriptions/$subscriptionId/resourceGroups/$resourceGroup/providers/Microsoft.OperationalInsights/workspaces/$analyticsWorkspace"
#Install script
bash enable-monitoring.sh --resource-id $azureArcClusterResourceId --kube-context $kubeContext --workspace-id $logAnalyticsWorkspaceResourceId
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment