-
Notifications
You must be signed in to change notification settings - Fork 758
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add dev container for codespaces * Add example for web-app-linux * Remove devcontainer after reading discussion in #455 * Add web-app-linux to index * format main.bicep * Trigger new workflow run. Nerdbank git versioning stuck process. * Add line at end of file
- Loading branch information
1 parent
4b3e8b1
commit fde03e1
Showing
3 changed files
with
93 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
param webAppName string = uniqueString(resourceGroup().id) // Generate unique String for web app name | ||
param sku string = 'S1' // The SKU of App Service Plan | ||
param linuxFxVersion string = 'php|7.4' // The runtime stack of web app | ||
param location string = resourceGroup().location // Location for all resources | ||
|
||
var appServicePlanName = toLower('AppServicePlan-${webAppName}') | ||
var webSiteName = toLower('wapp-${webAppName}') | ||
|
||
resource appServicePlan 'Microsoft.Web/serverfarms@2020-06-01' = { | ||
name: appServicePlanName | ||
location: location | ||
sku: { | ||
name: sku | ||
} | ||
kind: 'linux' | ||
properties: { | ||
reserved: true | ||
} | ||
} | ||
|
||
resource appService 'Microsoft.Web/sites@2020-06-01' = { | ||
name: webSiteName | ||
location: location | ||
kind: 'app' | ||
properties: { | ||
serverFarmId: appServicePlan.id | ||
siteConfig: { | ||
linuxFxVersion: linuxFxVersion | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
{ | ||
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#", | ||
"contentVersion": "1.0.0.0", | ||
"parameters": { | ||
"webAppName": { | ||
"type": "string", | ||
"defaultValue": "[uniqueString(resourceGroup().id)]" | ||
}, | ||
"sku": { | ||
"type": "string", | ||
"defaultValue": "S1" | ||
}, | ||
"linuxFxVersion": { | ||
"type": "string", | ||
"defaultValue": "php|7.4" | ||
}, | ||
"location": { | ||
"type": "string", | ||
"defaultValue": "[resourceGroup().location]" | ||
} | ||
}, | ||
"functions": [], | ||
"variables": { | ||
"appServicePlanName": "[toLower(format('AppServicePlan-{0}', parameters('webAppName')))]", | ||
"webSiteName": "[toLower(format('wapp-{0}', parameters('webAppName')))]" | ||
}, | ||
"resources": [ | ||
{ | ||
"type": "Microsoft.Web/serverfarms", | ||
"apiVersion": "2020-06-01", | ||
"name": "[variables('appServicePlanName')]", | ||
"location": "[parameters('location')]", | ||
"sku": { | ||
"name": "[parameters('sku')]" | ||
}, | ||
"kind": "linux", | ||
"properties": { | ||
"reserved": true | ||
} | ||
}, | ||
{ | ||
"type": "Microsoft.Web/sites", | ||
"apiVersion": "2020-06-01", | ||
"name": "[variables('webSiteName')]", | ||
"location": "[parameters('location')]", | ||
"kind": "app", | ||
"properties": { | ||
"serverFarmId": "[resourceId('Microsoft.Web/serverfarms', variables('appServicePlanName'))]", | ||
"siteConfig": { | ||
"linuxFxVersion": "[parameters('linuxFxVersion')]" | ||
} | ||
}, | ||
"dependsOn": [ | ||
"[resourceId('Microsoft.Web/serverfarms', variables('appServicePlanName'))]" | ||
] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters