Bahn: aisupport, Analyse-O2C-C2S, awesome-bahn-mcp-servers, beam-mcp,
Confluence_Bot, db-planet-mcp-server, O2C-Harness, project-audit,
Projekt-KIQ-HP, teamlandkarte-mcp
Dhive: Jury-Voting
Privat: CV, NoteGraph (NOTE: NoteGraph needs complete redo after consolidation)
Shared: AI-Orchestrator, OrgMyLife, power_skills_and_more
Shared/references: symphony (read-only)
Bahn repos remain available as independent remotes - this monorepo
pulls them in via subtree, the originals are untouched.
72 lines
2.0 KiB
Bicep
72 lines
2.0 KiB
Bicep
// Application Insights module
|
|
|
|
@description('The environment name (DEV, IAT, Prod)')
|
|
param environment string
|
|
|
|
@description('The location for Application Insights')
|
|
param location string
|
|
|
|
@description('Tags to apply to resources')
|
|
param tags object
|
|
|
|
@description('Unique token for resource naming')
|
|
param resourceToken string
|
|
|
|
@description('Key Vault name for storing connection string')
|
|
param keyVaultName string
|
|
|
|
var appInsightsName = 'appi-dbp-${toLower(environment)}-${resourceToken}'
|
|
var logAnalyticsWorkspaceName = 'log-dbp-${toLower(environment)}-${resourceToken}'
|
|
|
|
resource logAnalyticsWorkspace 'Microsoft.OperationalInsights/workspaces@2025-02-01' = {
|
|
name: logAnalyticsWorkspaceName
|
|
location: location
|
|
tags: tags
|
|
properties: {
|
|
sku: {
|
|
name: 'PerGB2018'
|
|
}
|
|
retentionInDays: environment == 'Prod' ? 90 : 30
|
|
features: {
|
|
enableLogAccessUsingOnlyResourcePermissions: true
|
|
}
|
|
}
|
|
}
|
|
|
|
resource applicationInsights 'Microsoft.Insights/components@2020-02-02' = {
|
|
name: appInsightsName
|
|
location: location
|
|
tags: tags
|
|
kind: 'web'
|
|
properties: {
|
|
Application_Type: 'web'
|
|
WorkspaceResourceId: logAnalyticsWorkspace.id
|
|
IngestionMode: 'LogAnalytics'
|
|
publicNetworkAccessForIngestion: 'Enabled'
|
|
publicNetworkAccessForQuery: 'Enabled'
|
|
}
|
|
}
|
|
|
|
|
|
resource keyVault 'Microsoft.KeyVault/vaults@2024-11-01' existing = {
|
|
name: keyVaultName
|
|
}
|
|
|
|
resource connectionStringSecret 'Microsoft.KeyVault/vaults/secrets@2024-11-01' = {
|
|
parent: keyVault
|
|
name: 'applicationinsights-connection-string'
|
|
properties: {
|
|
value: applicationInsights.properties.ConnectionString
|
|
attributes: {
|
|
enabled: true
|
|
}
|
|
}
|
|
}
|
|
|
|
output applicationInsightsName string = applicationInsights.name
|
|
output applicationInsightsId string = applicationInsights.id
|
|
output connectionString string = applicationInsights.properties.ConnectionString
|
|
output instrumentationKey string = applicationInsights.properties.InstrumentationKey
|
|
output logAnalyticsWorkspaceId string = logAnalyticsWorkspace.id
|
|
output logAnalyticsWorkspaceName string = logAnalyticsWorkspace.name
|