@@ -300,7 +300,7 @@ param webAppExists bool
300
300
@allowed (['appservice' , 'containerapps' ])
301
301
param deploymentTarget string = 'appservice'
302
302
param acaIdentityName string = deploymentTarget == 'containerapps' ? '${environmentName }-aca-identity' : ''
303
- param acaManagedEnvironmentName string = deploymentTarget == 'containerapps' ? '${environmentName }-aca-envnet ' : ''
303
+ param acaManagedEnvironmentName string = deploymentTarget == 'containerapps' ? '${environmentName }-aca-env ' : ''
304
304
param containerRegistryName string = deploymentTarget == 'containerapps'
305
305
? '${replace (toLower (environmentName ), '-' , '' )}acr'
306
306
: ''
@@ -542,7 +542,7 @@ module acaBackend 'core/host/container-app-upsert.bicep' = if (deploymentTarget
542
542
acaIdentity
543
543
]
544
544
params : {
545
- name : !empty (backendServiceName ) ? backendServiceName : '${abbrs .webSitesContainerApps }backend${resourceToken }'
545
+ name : !empty (backendServiceName ) ? backendServiceName : '${abbrs .webSitesContainerApps }backend- ${resourceToken }'
546
546
location : location
547
547
identityName : (deploymentTarget == 'containerapps' ) ? acaIdentityName : ''
548
548
exists : webAppExists
@@ -552,7 +552,7 @@ module acaBackend 'core/host/container-app-upsert.bicep' = if (deploymentTarget
552
552
targetPort : 8000
553
553
containerCpuCoreCount : '1.0'
554
554
containerMemory : '2Gi'
555
- containerMinReplicas : 1
555
+ containerMinReplicas : usePrivateEndpoint ? 1 : 0
556
556
allowedOrigins : allowedOrigins
557
557
env : union (appEnvVariables , {
558
558
// For using managed identity to access Azure resources. See https://github.com/microsoft/azure-container-apps/issues/442
@@ -1155,17 +1155,15 @@ module cosmosDbRoleBackend 'core/security/documentdb-sql-role.bicep' = if (useAu
1155
1155
}
1156
1156
}
1157
1157
1158
-
1159
-
1160
1158
module isolation 'network-isolation.bicep' = if (usePrivateEndpoint ) {
1161
1159
name : 'networks'
1162
1160
scope : resourceGroup
1163
1161
params : {
1164
1162
location : location
1165
1163
tags : tags
1166
1164
vnetName : '${abbrs .virtualNetworks }${resourceToken }'
1167
- useVpnGateway : useVpnGateway
1168
1165
deploymentTarget : deploymentTarget
1166
+ useVpnGateway : useVpnGateway
1169
1167
vpnGatewayName : useVpnGateway ? '${abbrs .networkVpnGateways }${resourceToken }' : ''
1170
1168
dnsResolverName : useVpnGateway ? '${abbrs .privateDnsResolver }${resourceToken }' : ''
1171
1169
}
0 commit comments