-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathaca-common.bicep
50 lines (46 loc) · 1.28 KB
/
aca-common.bicep
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
param location string
param logAnalyticsCustomerId string
param managedIdentityId string
param nsgName string
param subnetId string
param tags object
@secure()
param logAnalyticsKey string
resource containerAppsEnvironment 'Microsoft.App/managedEnvironments@2023-11-02-preview' = {
name: 'cae-aca-store'
location: location
identity: {
type: 'UserAssigned'
userAssignedIdentities: {
'${managedIdentityId}' : {}
}
}
properties: {
appLogsConfiguration: {
destination: 'log-analytics'
logAnalyticsConfiguration: {
customerId: logAnalyticsCustomerId
sharedKey: logAnalyticsKey
}
}
vnetConfiguration: {
infrastructureSubnetId: subnetId
}
zoneRedundant: true
}
tags: tags
}
resource containerAppsInboundNsgRule 'Microsoft.Network/networkSecurityGroups/securityRules@2023-05-01' = {
name: '${nsgName}/AllowInternet443FrontendInbound'
properties: {
protocol: 'TCP'
sourcePortRange: '*'
destinationPortRange: '443'
sourceAddressPrefix: 'Internet'
destinationAddressPrefix: containerAppsEnvironment.properties.staticIp
access: 'Allow'
priority: 100
direction: 'Inbound'
}
}
output environmentId string = containerAppsEnvironment.id