Skip to content

Commit 0cfaf22

Browse files
committed
Update Gemfile and bicep script
1 parent a4cc927 commit 0cfaf22

File tree

2 files changed

+107
-105
lines changed

2 files changed

+107
-105
lines changed

Gemfile.lock

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,12 @@ GEM
5757
rb-inotify (0.10.1)
5858
ffi (~> 1.0)
5959
rexml (3.2.8)
60+
strscan (>= 3.0.9)
6061
rouge (4.0.0)
6162
safe_yaml (1.0.5)
6263
sassc (2.4.0)
6364
ffi (~> 1.9)
65+
strscan (3.0.9)
6466
terminal-table (3.0.2)
6567
unicode-display_width (>= 1.1.1, < 3)
6668
unicode-display_width (2.3.0)
Lines changed: 105 additions & 105 deletions
Original file line numberDiff line numberDiff line change
@@ -1,105 +1,105 @@
1-
@description('Environment of the web app')
2-
param environment string = 'dev'
3-
4-
@description('Location of services')
5-
param location string = resourceGroup().location
6-
7-
var webAppName = '${uniqueString(resourceGroup().id)}-${environment}'
8-
var appServicePlanName = '${uniqueString(resourceGroup().id)}-mpnp-asp'
9-
var logAnalyticsName = '${uniqueString(resourceGroup().id)}-mpnp-la'
10-
var appInsightsName = '${uniqueString(resourceGroup().id)}-mpnp-ai'
11-
var sku = 'S1'
12-
var registryName = '${uniqueString(resourceGroup().id)}mpnpreg'
13-
var registrySku = 'Standard'
14-
var imageName = 'techexcel/dotnetcoreapp'
15-
var startupCommand = ''
16-
17-
18-
resource logAnalyticsWorkspace 'Microsoft.OperationalInsights/workspaces@2021-12-01-preview' = {
19-
name: logAnalyticsName
20-
location: location
21-
properties: {
22-
sku: {
23-
name: 'PerGB2018'
24-
}
25-
retentionInDays: 90
26-
workspaceCapping: {
27-
dailyQuotaGb: 1
28-
}
29-
}
30-
}
31-
32-
resource appInsights 'Microsoft.Insights/components@2020-02-02-preview' = {
33-
name: appInsightsName
34-
location: location
35-
kind: 'web'
36-
properties: {
37-
Application_Type: 'web'
38-
WorkspaceResourceId: logAnalyticsWorkspace.id
39-
}
40-
}
41-
42-
resource containerRegistry 'Microsoft.ContainerRegistry/registries@2020-11-01-preview' = {
43-
name: registryName
44-
location: location
45-
sku: {
46-
name: registrySku
47-
}
48-
properties: {
49-
adminUserEnabled: true
50-
}
51-
}
52-
53-
resource appServicePlan 'Microsoft.Web/serverFarms@2020-12-01' = {
54-
name: appServicePlanName
55-
location: location
56-
kind: 'linux'
57-
properties: {
58-
reserved: true
59-
}
60-
sku: {
61-
name: sku
62-
}
63-
}
64-
65-
resource appServiceApp 'Microsoft.Web/sites@2020-12-01' = {
66-
name: webAppName
67-
location: location
68-
properties: {
69-
serverFarmId: appServicePlan.id
70-
httpsOnly: true
71-
clientAffinityEnabled: false
72-
siteConfig: {
73-
linuxFxVersion: 'DOCKER|${containerRegistry.name}.azurecr.io/${uniqueString(resourceGroup().id)}/${imageName}'
74-
http20Enabled: true
75-
minTlsVersion: '1.2'
76-
appCommandLine: startupCommand
77-
appSettings: [
78-
{
79-
name: 'WEBSITES_ENABLE_APP_SERVICE_STORAGE'
80-
value: 'false'
81-
}
82-
{
83-
name: 'DOCKER_REGISTRY_SERVER_URL'
84-
value: 'https://${containerRegistry.name}.azurecr.io'
85-
}
86-
{
87-
name: 'DOCKER_REGISTRY_SERVER_USERNAME'
88-
value: containerRegistry.name
89-
}
90-
{
91-
name: 'DOCKER_REGISTRY_SERVER_PASSWORD'
92-
value: containerRegistry.listCredentials().passwords[0].value
93-
}
94-
{
95-
name: 'APPINSIGHTS_INSTRUMENTATIONKEY'
96-
value: appInsights.properties.InstrumentationKey
97-
}
98-
]
99-
}
100-
}
101-
}
102-
103-
output application_name string = appServiceApp.name
104-
output application_url string = appServiceApp.properties.hostNames[0]
105-
output container_registry_name string = containerRegistry.name
1+
@description('Environment of the web app')
2+
param environment string = 'dev'
3+
4+
@description('Location of services')
5+
param location string = resourceGroup().location
6+
7+
var webAppName = '${uniqueString(resourceGroup().id)}-${environment}'
8+
var appServicePlanName = '${uniqueString(resourceGroup().id)}-mpnp-asp'
9+
var logAnalyticsName = '${uniqueString(resourceGroup().id)}-mpnp-la'
10+
var appInsightsName = '${uniqueString(resourceGroup().id)}-mpnp-ai'
11+
var sku = 'P0V3'
12+
var registryName = '${uniqueString(resourceGroup().id)}mpnpreg'
13+
var registrySku = 'Standard'
14+
var imageName = 'techexcel/dotnetcoreapp'
15+
var startupCommand = ''
16+
17+
18+
resource logAnalyticsWorkspace 'Microsoft.OperationalInsights/workspaces@2021-12-01-preview' = {
19+
name: logAnalyticsName
20+
location: location
21+
properties: {
22+
sku: {
23+
name: 'PerGB2018'
24+
}
25+
retentionInDays: 90
26+
workspaceCapping: {
27+
dailyQuotaGb: 1
28+
}
29+
}
30+
}
31+
32+
resource appInsights 'Microsoft.Insights/components@2020-02-02-preview' = {
33+
name: appInsightsName
34+
location: location
35+
kind: 'web'
36+
properties: {
37+
Application_Type: 'web'
38+
WorkspaceResourceId: logAnalyticsWorkspace.id
39+
}
40+
}
41+
42+
resource containerRegistry 'Microsoft.ContainerRegistry/registries@2020-11-01-preview' = {
43+
name: registryName
44+
location: location
45+
sku: {
46+
name: registrySku
47+
}
48+
properties: {
49+
adminUserEnabled: true
50+
}
51+
}
52+
53+
resource appServicePlan 'Microsoft.Web/serverFarms@2020-12-01' = {
54+
name: appServicePlanName
55+
location: location
56+
kind: 'linux'
57+
properties: {
58+
reserved: true
59+
}
60+
sku: {
61+
name: sku
62+
}
63+
}
64+
65+
resource appServiceApp 'Microsoft.Web/sites@2020-12-01' = {
66+
name: webAppName
67+
location: location
68+
properties: {
69+
serverFarmId: appServicePlan.id
70+
httpsOnly: true
71+
clientAffinityEnabled: false
72+
siteConfig: {
73+
linuxFxVersion: 'DOCKER|${containerRegistry.name}.azurecr.io/${uniqueString(resourceGroup().id)}/${imageName}'
74+
http20Enabled: true
75+
minTlsVersion: '1.2'
76+
appCommandLine: startupCommand
77+
appSettings: [
78+
{
79+
name: 'WEBSITES_ENABLE_APP_SERVICE_STORAGE'
80+
value: 'false'
81+
}
82+
{
83+
name: 'DOCKER_REGISTRY_SERVER_URL'
84+
value: 'https://${containerRegistry.name}.azurecr.io'
85+
}
86+
{
87+
name: 'DOCKER_REGISTRY_SERVER_USERNAME'
88+
value: containerRegistry.name
89+
}
90+
{
91+
name: 'DOCKER_REGISTRY_SERVER_PASSWORD'
92+
value: containerRegistry.listCredentials().passwords[0].value
93+
}
94+
{
95+
name: 'APPINSIGHTS_INSTRUMENTATIONKEY'
96+
value: appInsights.properties.InstrumentationKey
97+
}
98+
]
99+
}
100+
}
101+
}
102+
103+
output application_name string = appServiceApp.name
104+
output application_url string = appServiceApp.properties.hostNames[0]
105+
output container_registry_name string = containerRegistry.name

0 commit comments

Comments
 (0)