Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions infra/main.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,16 @@ module applicationInsights 'br/public:avm/res/insights/component:0.6.0' = {
}
}

// ========== Resource Group Tag ========== //
resource resourceGroupTags 'Microsoft.Resources/tags@2021-04-01' = {
name: 'default'
properties: {
tags: {
TemplateName: 'Content Processing'
}
}
}

// ========== Managed Identity ========== //
module avmManagedIdentity './modules/managed-identity.bicep' = {
params: {
Expand Down
98 changes: 54 additions & 44 deletions infra/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "961802883849358046"
"version": "0.36.177.2456",
"templateHash": "5192359171136519746"
},
"name": "Content Processing Solution Accelerator",
"description": "Bicep template to deploy the Content Processing Solution Accelerator with AVM compliance."
Expand Down Expand Up @@ -219,6 +219,16 @@
}
}
},
"resourceGroupTags": {
"type": "Microsoft.Resources/tags",
"apiVersion": "2021-04-01",
"name": "default",
"properties": {
"tags": {
"TemplateName": "Content Processing"
}
}
},
"avmNetworkSecurityGroup": {
"condition": "[parameters('enablePrivateNetworking')]",
"type": "Microsoft.Resources/deployments",
Expand All @@ -245,7 +255,7 @@
"diagnosticSettings": {
"value": [
{
"workspaceResourceId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"workspaceResourceId": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
}
]
},
Expand Down Expand Up @@ -925,7 +935,7 @@
"diagnosticSettings": {
"value": [
{
"workspaceResourceId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"workspaceResourceId": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
}
]
},
Expand Down Expand Up @@ -1670,7 +1680,7 @@
"diagnosticSettings": {
"value": [
{
"workspaceResourceId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"workspaceResourceId": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
}
]
},
Expand Down Expand Up @@ -2350,7 +2360,7 @@
"diagnosticSettings": {
"value": [
{
"workspaceResourceId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"workspaceResourceId": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
}
]
},
Expand Down Expand Up @@ -3035,7 +3045,7 @@
"diagnosticSettings": {
"value": [
{
"workspaceResourceId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"workspaceResourceId": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
}
]
},
Expand Down Expand Up @@ -7898,8 +7908,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "15981152896828585106"
"version": "0.36.177.2456",
"templateHash": "3906046175102371285"
}
},
"parameters": {
Expand Down Expand Up @@ -11014,15 +11024,15 @@
"outputs": {
"resourceId": {
"type": "string",
"value": "[if(variables('useExistingWorkspace'), extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', variables('existingLawSubscription'), variables('existingLawResourceGroup')), 'Microsoft.OperationalInsights/workspaces', variables('existingLawName')), listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_new_log_analytics_workspace'), '2022-09-01').resourceId)]"
"value": "[if(variables('useExistingWorkspace'), extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', variables('existingLawSubscription'), variables('existingLawResourceGroup')), 'Microsoft.OperationalInsights/workspaces', variables('existingLawName')), reference('logAnalyticsWorkspace').outputs.resourceId.value)]"
},
"logAnalyticsWorkspaceId": {
"type": "string",
"value": "[if(variables('useExistingWorkspace'), reference('existingLogAnalyticsWorkspace').customerId, listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_new_log_analytics_workspace'), '2022-09-01').logAnalyticsWorkspaceId)]"
"value": "[if(variables('useExistingWorkspace'), reference('existingLogAnalyticsWorkspace').customerId, reference('logAnalyticsWorkspace').outputs.logAnalyticsWorkspaceId.value)]"
},
"primarySharedKey": {
"type": "securestring",
"value": "[if(variables('useExistingWorkspace'), if(variables('useExistingWorkspace'), listKeys(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', variables('existingLawSubscription'), variables('existingLawResourceGroup')), 'Microsoft.OperationalInsights/workspaces', variables('existingLawName')), '2020-08-01'), listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_new_log_analytics_workspace'), '2022-09-01').primarySharedKey).primarySharedKey, listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_new_log_analytics_workspace'), '2022-09-01').primarySharedKey)]"
"value": "[if(variables('useExistingWorkspace'), if(variables('useExistingWorkspace'), listKeys(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', variables('existingLawSubscription'), variables('existingLawResourceGroup')), 'Microsoft.OperationalInsights/workspaces', variables('existingLawName')), '2020-08-01'), listOutputsWithSecureValues('logAnalyticsWorkspace', '2022-09-01').primarySharedKey).primarySharedKey, listOutputsWithSecureValues('logAnalyticsWorkspace', '2022-09-01').primarySharedKey)]"
}
}
}
Expand All @@ -11045,12 +11055,12 @@
"value": "[parameters('location')]"
},
"workspaceResourceId": {
"value": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"value": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
},
"diagnosticSettings": {
"value": [
{
"workspaceResourceId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"workspaceResourceId": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
}
]
},
Expand Down Expand Up @@ -11783,8 +11793,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "2317259662067975763"
"version": "0.36.177.2456",
"templateHash": "14410385321137128263"
}
},
"parameters": {
Expand Down Expand Up @@ -12358,7 +12368,7 @@
},
"publicNetworkAccess": "[if(parameters('enablePrivateNetworking'), createObject('value', 'Disabled'), createObject('value', 'Enabled'))]",
"logAnalyticsWorkspaceResourceId": {
"value": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"value": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
},
"networkAcls": {
"value": {
Expand All @@ -12373,8 +12383,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "12497992766525707634"
"version": "0.36.177.2456",
"templateHash": "12745773382509549839"
},
"name": "Key Vault Module"
},
Expand Down Expand Up @@ -15912,8 +15922,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "11910096117865508081"
"version": "0.36.177.2456",
"templateHash": "11092248228709008584"
},
"name": "Container Registry Module"
},
Expand Down Expand Up @@ -24942,7 +24952,7 @@
"diagnosticSettings": {
"value": [
{
"workspaceResourceId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]"
"workspaceResourceId": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]"
}
]
},
Expand Down Expand Up @@ -24998,8 +25008,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "16330577693396165210"
"version": "0.36.177.2456",
"templateHash": "5761548449731819585"
},
"name": "Cognitive Services",
"description": "This module deploys a Cognitive Service."
Expand Down Expand Up @@ -26248,8 +26258,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "4128376395637895528"
"version": "0.36.177.2456",
"templateHash": "11270933172961789567"
}
},
"definitions": {
Expand Down Expand Up @@ -28057,8 +28067,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "1200612323329026557"
"version": "0.36.177.2456",
"templateHash": "9150529619101779014"
}
},
"definitions": {
Expand Down Expand Up @@ -28211,8 +28221,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "125568697111155565"
"version": "0.36.177.2456",
"templateHash": "18131656256983910282"
}
},
"definitions": {
Expand Down Expand Up @@ -28429,8 +28439,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "4128376395637895528"
"version": "0.36.177.2456",
"templateHash": "11270933172961789567"
}
},
"definitions": {
Expand Down Expand Up @@ -30238,8 +30248,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "1200612323329026557"
"version": "0.36.177.2456",
"templateHash": "9150529619101779014"
}
},
"definitions": {
Expand Down Expand Up @@ -30392,8 +30402,8 @@
"metadata": {
"_generator": {
"name": "bicep",
"version": "0.36.1.42791",
"templateHash": "125568697111155565"
"version": "0.36.177.2456",
"templateHash": "18131656256983910282"
}
},
"definitions": {
Expand Down Expand Up @@ -30633,10 +30643,10 @@
"dependsOn": [
"avmContainerApp",
"avmManagedIdentity",
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').aiServices)]",
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').openAI)]",
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').contentUnderstanding)]",
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').cognitiveServices)]",
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').aiServices)]",
"avmVirtualNetwork",
"logAnalyticsWorkspace"
]
Expand Down Expand Up @@ -32974,8 +32984,8 @@
"dependsOn": [
"avmContainerApp",
"avmManagedIdentity",
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').contentUnderstanding)]",
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').cognitiveServices)]",
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').contentUnderstanding)]",
"avmVirtualNetwork"
]
},
Expand Down Expand Up @@ -33010,8 +33020,8 @@
"value": {
"destination": "log-analytics",
"logAnalyticsConfiguration": {
"customerId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').logAnalyticsWorkspaceId]",
"sharedKey": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').primarySharedKey]"
"customerId": "[reference('logAnalyticsWorkspace').outputs.logAnalyticsWorkspaceId.value]",
"sharedKey": "[listOutputsWithSecureValues('logAnalyticsWorkspace', '2022-09-01').primarySharedKey]"
}
}
},
Expand Down Expand Up @@ -42891,7 +42901,7 @@
"diagnosticSettings": {
"value": [
{
"workspaceResourceId": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', 'deploy_log_analytics_workspace'), '2022-09-01').resourceId]",
"workspaceResourceId": "[reference('logAnalyticsWorkspace').outputs.resourceId.value]",
"logCategoriesAndGroups": [
{
"categoryGroup": "allLogs",
Expand Down Expand Up @@ -42989,19 +42999,19 @@
},
{
"name": "APP_STORAGE_BLOB_URL",
"value": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', format(parameters('resourceNameFormatString'), 'st')), '2022-09-01').serviceEndpoints.blob]"
"value": "[reference('avmStorageAccount').outputs.serviceEndpoints.value.blob]"
},
{
"name": "APP_STORAGE_QUEUE_URL",
"value": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', format(parameters('resourceNameFormatString'), 'st')), '2022-09-01').serviceEndpoints.queue]"
"value": "[reference('avmStorageAccount').outputs.serviceEndpoints.value.queue]"
},
{
"name": "APP_AI_PROJECT_ENDPOINT",
"value": "[reference('avmAiServices').outputs.aiProjectInfo.value.apiEndpoint]"
},
{
"name": "APP_COSMOS_CONNSTR",
"value": "[listOutputsWithSecureValues(resourceId('Microsoft.Resources/deployments', format(parameters('resourceNameFormatString'), 'cosmos-')), '2022-09-01').primaryReadWriteConnectionString]"
"value": "[listOutputsWithSecureValues('avmCosmosDB', '2022-09-01').primaryReadWriteConnectionString]"
}
]
},
Expand Down
Loading