Web App with custom Deployment slots
This template provides an easy way to deploy web app with custom deployment slots/environments on Azure Web Apps.
The template includes a sample for how to deploy sticky slot settings (i.e. deployment slot settings) via the Microsoft.Web/sites/config
resource. Sticky connection strings can be added the same way using the connectionStringNames
property.
The environments
parameter (array) can be used to specify different slot/environment names, and a slot will be created for every item listed in the array.
To specify multiple environments, say N, follow this simple rule:
Add N - 1 items, as depicted in the below example, with N = 5. There's always a default "nameless" slot created by default:
// Environments -> Deployment slots will be created for every environment listed here
"environments": {
"value": [
"Dev",
"Next",
"Preview",
"Future"
// A default, "nameless" slot will be created; so don't list it here
]
}
Please note that different app service plans has different caps on the number of slots that can be created.
For example, at the time of this writing, a Standard plan puts a cap of 5 and a Premium plan 20. The Free, Shared or Basic plans are not allowed to have any slots.
Tags: Microsoft.Web/serverfarms, Microsoft.Web/sites, Microsoft.Web/sites/slots, Microsoft.Web/sites/config