Skip to content

Instantly share code, notes, and snippets.

@ThomasPe
Created September 5, 2022 14:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ThomasPe/4a3776a1c3375a95949abd54e26847bc to your computer and use it in GitHub Desktop.
Save ThomasPe/4a3776a1c3375a95949abd54e26847bc to your computer and use it in GitHub Desktop.
Bicep Template for Application Insights + Log Analytics Workspace
resource logAnalyticsWorkspace 'Microsoft.OperationalInsights/workspaces@2021-12-01-preview' = {
name: resourceBaseName
location: resourceGroup().location
properties: {
sku: {
name: 'PerGB2018'
}
retentionInDays: 90
workspaceCapping: {
dailyQuotaGb: '0.023'
}
}
}
resource applicationInsights 'Microsoft.Insights/components@2020-02-02' = {
name: resourceBaseName
location: resourceGroup().location
kind: 'web'
properties: {
Application_Type: 'web'
WorkspaceResourceId: logAnalyticsWorkspace.id
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment