Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- "resources": [
- {
- "apiVersion": "2015-08-01",
- "name": "appsettings",
- "type": "config",
- "dependsOn": [
- "[resourceId('Microsoft.Web/Sites/Slots', variables('webSiteName'), 'Staging')]"
- ],
- "properties": {
- "AppSettingKey1": "Some staging value",
- "AppSettingKey2": "My second staging setting",
- "AppSettingKey3": "My third staging setting"
- }
- }
- ]
- {
- "$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
- "contentVersion": "1.0.0.0",
- "parameters": {
- "hostingPlanName": {
- "type": "string",
- "minLength": 1
- },
- "skuName": {
- "type": "string",
- "defaultValue": "S1",
- "allowedValues": [
- "F1",
- "D1",
- "B1",
- "B2",
- "B3",
- "S1",
- "S2",
- "S3",
- "P1",
- "P2",
- "P3",
- "P4"
- ],
- "metadata": {
- "description": "Describes plan's pricing tier and instance size. Check details at https://azure.microsoft.com/en-us/pricing/details/app-service/"
- }
- },
- "skuCapacity": {
- "type": "int",
- "defaultValue": 1,
- "minValue": 1,
- "metadata": {
- "description": "Describes plan's instance count"
- }
- }
- },
- "variables": {
- "webSiteName": "[concat('webSite', uniqueString(resourceGroup().id))]"
- },
- "resources": [
- {
- "apiVersion": "2015-08-01",
- "name": "[parameters('hostingPlanName')]",
- "type": "Microsoft.Web/serverfarms",
- "location": "[resourceGroup().location]",
- "tags": {
- "displayName": "HostingPlan"
- },
- "sku": {
- "name": "[parameters('skuName')]",
- "capacity": "[parameters('skuCapacity')]"
- },
- "properties": {
- "name": "[parameters('hostingPlanName')]"
- }
- },
- {
- "apiVersion": "2015-08-01",
- "dependsOn": [
- "[concat('Microsoft.Web/serverfarms/', parameters('hostingPlanName'))]"
- ],
- "location": "[resourceGroup().location]",
- "name": "[variables('webSiteName')]",
- "properties": {
- "name": "[variables('webSiteName')]",
- "serverFarmId": "[resourceId('Microsoft.Web/serverfarms', parameters('hostingPlanName'))]"
- },
- "resources": [
- {
- "apiVersion": "2015-08-01",
- "name": "Staging",
- "type": "slots",
- "location": "[resourceGroup().location]",
- "dependsOn": [
- "[resourceId('Microsoft.Web/Sites', variables('webSiteName'))]"
- ],
- "properties": {
- },
- "resources": [
- {
- "apiVersion": "2015-08-01",
- "name": "appsettings",
- "type": "config",
- "dependsOn": [
- "[resourceId('Microsoft.Web/Sites/Slots', variables('webSiteName'), 'Staging')]"
- ],
- "properties": {
- "AppSettingKey1": "Some staging value",
- "AppSettingKey2": "My second staging setting",
- "AppSettingKey3": "My third staging setting"
- }
- }
- ]
- }
- ],
- "tags": {
- "[concat('hidden-related:', resourceGroup().id, '/providers/Microsoft.Web/serverfarms/', parameters('hostingPlanName'))]": "Resource",
- "displayName": "Website"
- },
- "type": "Microsoft.Web/sites"
- }
- ]
- }
- "resources": [
- {
- "apiVersion": "2015-08-01",
- "name": "appsettings",
- "type": "config",
- "dependsOn": [
- "[resourceId('Microsoft.Web/Sites/Slots', variables('webSiteName'), 'Staging')]"
- ],
- "properties": {
- "AppSettingKey1": "Some staging value",
- "AppSettingKey2": "My second staging setting",
- "AppSettingKey3": "My third staging setting"
- },
- {
- "apiVersion": "2015-08-01",
- "name": "slotconfignames",
- "type": "config",
- "dependsOn": [
- "[resourceId('Microsoft.Web/Sites', variables('webSiteName'))]"
- ],
- "properties": {
- "appSettingNames": [ "AppSettingKey1", "AppSettingKey2" ]
- }
- }
- ]
- "resources": [
- {
- "apiVersion":"[variables('siteApiVersion')]",
- "name":"[variables('WebAppName')]",
- "type":"Microsoft.Web/sites",
- "kind":"api",
- "location":"[variables('location')]",
- "tags":{
- "[concat('hidden-related:', resourceId('Microsoft.Web/serverfarms', variables('hostingPlanName')))]":"empty"
- },
- "properties":{
- "name":"[variables('WebAppName')]",
- "serverFarmId":"[resourceId('Microsoft.Web/serverfarms', variables('hostingPlanName'))]",
- "siteConfig":{
- "AlwaysOn":"[parameters('AppServiceAlwaysOn')]"
- }
- },
- "resources":[
- {
- "apiVersion":"[variables('apiVersion')]",
- "type":"config",
- "name":"appsettings",
- "dependsOn":[
- "[variables('WebAppName')]"
- ],
- "properties":{}
- },
- {
- "apiVersion":"[variables('siteApiVersion')]",
- "type": "config",
- "name": "slotconfignames",
- "dependsOn": [
- "[concat('Microsoft.Web/sites/', variables('WebAppName'))]"
- ],
- "properties": {
- "appSettingNames": [ "WEBJOBS_DISABLE_SCHEDULE" ]
- }
- },
- {
- "apiVersion":"[variables('siteApiVersion')]",
- "condition":"[parameters('stagingSlotEnabled')]",
- "name":"[parameters('stagingSlotName')]",
- "type":"slots",
- "tags":{
- "displayName":"[concat(variables('WebAppName'), ' ', parameters('stagingSlotName'))]"
- },
- "location":"[variables('location')]",
- "dependsOn":[
- "[resourceId('Microsoft.Web/Sites', variables('WebAppName'))]"
- ],
- "properties":{},
- "resources":[
- {
- "apiVersion":"[variables('apiVersion')]",
- "type":"config",
- "name":"appsettings",
- "dependsOn":[
- "[resourceId('Microsoft.Web/Sites/Slots', variables('WebAppName'), parameters('stagingSlotName'))]"
- ],
- "properties":{
- "WEBJOBS_DISABLE_SCHEDULE" : "1"
- }
- }
- ]
- }
- ]
- }
Add Comment
Please, Sign In to add comment