Skip to content

Commit 4503d5b

Browse files
fix: address PR review - remove unneeded SecurityEvent DCR/solution
Revert the Microsoft.OperationsManagement/solutions 'Security' resource and the Microsoft-SecurityEvent data source/dataflow added in the previous commit. The SecurityEvent table is not provisioned by OMSGallery/Security in modern subscriptions and this workload has no Windows VMs to source the events, which was causing 'InvalidOutputTable' deployment failures. Retain only the storage account double-encryption change.
1 parent 06df144 commit 4503d5b

3 files changed

Lines changed: 5 additions & 101 deletions

File tree

infra/main.bicep

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -514,27 +514,12 @@ module maintenanceConfiguration 'br/public:avm/res/maintenance/maintenance-confi
514514
}
515515
}
516516

517-
resource securitySolution 'Microsoft.OperationsManagement/solutions@2015-11-01-preview' = if (enablePrivateNetworking && enableMonitoring) {
518-
name: 'Security(log-${solutionSuffix})'
519-
location: location
520-
plan: {
521-
name: 'Security(log-${solutionSuffix})'
522-
publisher: 'Microsoft'
523-
product: 'OMSGallery/Security'
524-
promotionCode: ''
525-
}
526-
properties: {
527-
workspaceResourceId: logAnalyticsWorkspaceResourceId
528-
}
529-
}
530-
531517
var dataCollectionRulesResourceName = 'dcr-${solutionSuffix}'
532518
var dataCollectionRulesLocation = useExistingLogAnalytics
533519
? existingLogAnalyticsWorkspace!.location
534520
: logAnalyticsWorkspace!.outputs.location
535521
module windowsVmDataCollectionRules 'br/public:avm/res/insights/data-collection-rule:0.11.0' = if (enablePrivateNetworking && enableMonitoring) {
536522
name: take('avm.res.insights.data-collection-rule.${dataCollectionRulesResourceName}', 64)
537-
dependsOn: [securitySolution]
538523
params: {
539524
name: dataCollectionRulesResourceName
540525
tags: tags
@@ -601,17 +586,6 @@ module windowsVmDataCollectionRules 'br/public:avm/res/insights/data-collection-
601586
name: 'perfCounterDataSource60'
602587
}
603588
]
604-
windowsEventLogs: [
605-
{
606-
name: 'SecurityAuditEvents'
607-
streams: [
608-
'Microsoft-SecurityEvent'
609-
]
610-
xPathQueries: [
611-
'Security!*[System[(EventID=4624 or EventID=4625)]]'
612-
]
613-
}
614-
]
615589
}
616590
destinations: {
617591
logAnalytics: [
@@ -630,14 +604,6 @@ module windowsVmDataCollectionRules 'br/public:avm/res/insights/data-collection-
630604
'la-${dataCollectionRulesResourceName}'
631605
]
632606
}
633-
{
634-
streams: [
635-
'Microsoft-SecurityEvent'
636-
]
637-
destinations: [
638-
'la-${dataCollectionRulesResourceName}'
639-
]
640-
}
641607
]
642608
}
643609
}

infra/main.json

Lines changed: 4 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"_generator": {
77
"name": "bicep",
88
"version": "0.42.1.51946",
9-
"templateHash": "16804124823752948659"
9+
"templateHash": "17498808897015217801"
1010
},
1111
"name": "Modernize Your Code Solution Accelerator",
1212
"description": "CSA CTO Gold Standard Solution Accelerator for Modernize Your Code. \r\n"
@@ -308,25 +308,6 @@
308308
"resourceGroup": "[variables('existingLawResourceGroup')]",
309309
"name": "[variables('existingLawName')]"
310310
},
311-
"securitySolution": {
312-
"condition": "[and(parameters('enablePrivateNetworking'), parameters('enableMonitoring'))]",
313-
"type": "Microsoft.OperationsManagement/solutions",
314-
"apiVersion": "2015-11-01-preview",
315-
"name": "[format('Security(log-{0})', variables('solutionSuffix'))]",
316-
"location": "[parameters('location')]",
317-
"plan": {
318-
"name": "[format('Security(log-{0})', variables('solutionSuffix'))]",
319-
"publisher": "Microsoft",
320-
"product": "OMSGallery/Security",
321-
"promotionCode": ""
322-
},
323-
"properties": {
324-
"workspaceResourceId": "[if(variables('useExistingLogAnalytics'), parameters('existingLogAnalyticsWorkspaceId'), reference('logAnalyticsWorkspace').outputs.resourceId.value)]"
325-
},
326-
"dependsOn": [
327-
"logAnalyticsWorkspace"
328-
]
329-
},
330311
"appIdentity": {
331312
"type": "Microsoft.Resources/deployments",
332313
"apiVersion": "2025-04-01",
@@ -13120,11 +13101,11 @@
1312013101
},
1312113102
"dependsOn": [
1312213103
"applicationInsights",
13123-
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').agentSvc)]",
1312413104
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').monitor)]",
1312513105
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').oms)]",
1312613106
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').storageBlob)]",
1312713107
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').ods)]",
13108+
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').agentSvc)]",
1312813109
"dataCollectionEndpoint",
1312913110
"logAnalyticsWorkspace",
1313013111
"virtualNetwork"
@@ -15370,17 +15351,6 @@
1537015351
],
1537115352
"name": "perfCounterDataSource60"
1537215353
}
15373-
],
15374-
"windowsEventLogs": [
15375-
{
15376-
"name": "SecurityAuditEvents",
15377-
"streams": [
15378-
"Microsoft-SecurityEvent"
15379-
],
15380-
"xPathQueries": [
15381-
"Security!*[System[(EventID=4624 or EventID=4625)]]"
15382-
]
15383-
}
1538415354
]
1538515355
},
1538615356
"destinations": {
@@ -15399,14 +15369,6 @@
1539915369
"destinations": [
1540015370
"[format('la-{0}', variables('dataCollectionRulesResourceName'))]"
1540115371
]
15402-
},
15403-
{
15404-
"streams": [
15405-
"Microsoft-SecurityEvent"
15406-
],
15407-
"destinations": [
15408-
"[format('la-{0}', variables('dataCollectionRulesResourceName'))]"
15409-
]
1541015372
}
1541115373
]
1541215374
}
@@ -16616,8 +16578,7 @@
1661616578
"dependsOn": [
1661716579
"dataCollectionEndpoint",
1661816580
"existingLogAnalyticsWorkspace",
16619-
"logAnalyticsWorkspace",
16620-
"securitySolution"
16581+
"logAnalyticsWorkspace"
1662116582
]
1662216583
},
1662316584
"proximityPlacementGroup": {
@@ -32056,8 +32017,8 @@
3205632017
},
3205732018
"dependsOn": [
3205832019
"aiServices",
32059-
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').openAI)]",
3206032020
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').aiServices)]",
32021+
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').openAI)]",
3206132022
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').cognitiveServices)]",
3206232023
"virtualNetwork"
3206332024
]

infra/main_custom.bicep

Lines changed: 1 addition & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -422,27 +422,12 @@ module maintenanceConfiguration 'br/public:avm/res/maintenance/maintenance-confi
422422
}
423423
}
424424

425-
resource securitySolution 'Microsoft.OperationsManagement/solutions@2015-11-01-preview' = if (enablePrivateNetworking && enableMonitoring) {
426-
name: 'Security(log-${solutionSuffix})'
427-
location: location
428-
plan: {
429-
name: 'Security(log-${solutionSuffix})'
430-
publisher: 'Microsoft'
431-
product: 'OMSGallery/Security'
432-
promotionCode: ''
433-
}
434-
properties: {
435-
workspaceResourceId: logAnalyticsWorkspaceResourceId
436-
}
437-
}
438-
439425
var dataCollectionRulesResourceName = 'dcr-${solutionSuffix}'
440426
var dataCollectionRulesLocation = useExistingLogAnalytics
441427
? existingLogAnalyticsWorkspace!.location
442428
: logAnalyticsWorkspace!.outputs.location
443429
module windowsVmDataCollectionRules 'br/public:avm/res/insights/data-collection-rule:0.11.0' = if (enablePrivateNetworking && enableMonitoring) {
444430
name: take('avm.res.insights.data-collection-rule.${dataCollectionRulesResourceName}', 64)
445-
dependsOn: [securitySolution]
446431
params: {
447432
name: dataCollectionRulesResourceName
448433
tags: tags
@@ -512,7 +497,7 @@ module windowsVmDataCollectionRules 'br/public:avm/res/insights/data-collection-
512497
{
513498
name: 'SecurityAuditEvents'
514499
streams: [
515-
'Microsoft-SecurityEvent'
500+
'Microsoft-WindowsEvent'
516501
]
517502
xPathQueries: [
518503
'Security!*[System[(EventID=4624 or EventID=4625)]]'
@@ -539,14 +524,6 @@ module windowsVmDataCollectionRules 'br/public:avm/res/insights/data-collection-
539524
transformKql: 'source'
540525
outputStream: 'Microsoft-Perf'
541526
}
542-
{
543-
streams: [
544-
'Microsoft-SecurityEvent'
545-
]
546-
destinations: [
547-
'la-${dataCollectionRulesResourceName}'
548-
]
549-
}
550527
]
551528
}
552529
}

0 commit comments

Comments
 (0)