@@ -36,10 +36,6 @@ param externalStorageKeySecretName string
3636@description ('The Application Insights Instrumentation.' )
3737param appInsightsInstrumentationKey string
3838
39- // @secure()
40- // @description('The External Azure Stroage Access key for the Backend Background Processor Service.')
41- // param externalAzureStroageKeySecretValue string
42-
4339// Service Bus
4440@description ('The name of the service bus namespace.' )
4541param serviceBusName string
@@ -70,7 +66,7 @@ param containerRegistryPasswordRefName string
7066param containerRegistryPassword string
7167
7268@description ('The image for the backend processor service.' )
73- param backendProcessoServiceImage string
69+ param backendProcessorServiceImage string
7470
7571
7672// ------------------
@@ -82,9 +78,6 @@ var keyVaultSubscriptionId = keyVaultIdTokens[2]
8278var keyVaultResourceGroupName = keyVaultIdTokens [4 ]
8379var keyVaultName = keyVaultIdTokens [8 ]
8480
85- // var containerAppName = 'ca-${backendProcessorServiceName}'
86- var containerAppName = backendProcessorServiceName
87-
8881// ------------------
8982// RESOURCES
9083// ------------------
@@ -109,7 +102,7 @@ resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' existing
109102}
110103
111104resource backendProcessorService 'Microsoft.App/containerApps@2022-06-01-preview' = {
112- name : containerAppName
105+ name : backendProcessorServiceName
113106 location : location
114107 tags : tags
115108 identity : {
@@ -153,7 +146,7 @@ resource backendProcessorService 'Microsoft.App/containerApps@2022-06-01-preview
153146 containers : [
154147 {
155148 name : backendProcessorServiceName
156- image : backendProcessoServiceImage
149+ image : backendProcessorServiceImage
157150 resources : {
158151 cpu : json ('0.25' )
159152 memory : '0.5Gi'
@@ -200,8 +193,6 @@ resource backendProcessorService 'Microsoft.App/containerApps@2022-06-01-preview
200193}
201194
202195
203-
204-
205196// Enable consume from servicebus using system managed identity.
206197resource backendProcessorService_sb_role_assignment 'Microsoft.Authorization/roleAssignments@2020-04-01-preview' = {
207198 name : guid (resourceGroup ().id , backendProcessorServiceName , '4f6d3b9b-027b-4f4c-9142-0e5a2a2247e0' )
@@ -210,11 +201,10 @@ resource backendProcessorService_sb_role_assignment 'Microsoft.Authorization/rol
210201 roleDefinitionId : resourceId ('Microsoft.Authorization/roleDefinitions' , '4f6d3b9b-027b-4f4c-9142-0e5a2a2247e0' ) // Azure Service Bus Data Receiver.
211202 principalType : 'ServicePrincipal'
212203 }
213- //scope: serviceBusTopicSubscription
214204 scope : serviceBusNamespace
215205}
216206
217- // Create secrets and assigne Secrets User role to the backend processor service
207+ // Invoke create secrets and assign role 'Azure Role Key Vault Secrets User' to the backend processor service
218208module backendProcessorKeySecret 'secrets/processor-backend-service-secrets.bicep' = {
219209 name : 'backendProcessorKeySecret-${uniqueString (resourceGroup ().id )}'
220210 params : {
0 commit comments