Azure App Service ¶
Azure App Service enables you to build and host web apps, mobile back-ends, and RESTful APIs in the programming language of your choice without managing infrastructure. It offers auto-scaling and high availability, supports both Windows and Linux, and enables automated deployments from GitHub, Azure DevOps, or any Git repo.
Azure App Service is Microsoftโs PaaS
offering. Azure App Service comes in four flavors.
- Azure Web Apps/WebJobs
- Azure App Service Web App for Containers
- Azure Mobile Apps
- Azure API Apps
App Service Plan¶
An App Service plan
defines a set of compute resources for a web app to run. An app service
always runs in an App Service plan
. In addition, Azure Functions
also has the option of running in an App Service plan.
Contents of Azure app service
- Operating System (Windows, Linux)
- Region (West US, East US, etc.)
- Number of VM instances
- Size of VM instances (Small, Medium, Large)
- Pricing tier
App Service plans are created at a regional scope. When you create an App Service plan
in a certain region (for example, West Europe), a set of compute resources is created for that plan in that region. Whatever apps you put into this App Service plan run on these compute resources as defined by your App Service plan.
Moving webapp in App service
You can move an app to another App Service plan, as long as the source plan and the target plan are in the same resource group and geographical region. The region in which your app runs is the region of the App Service plan it's in. However, you cannot change an App Service plan's region.
Pricing tier¶
The pricing tier of an App Service plan determines what App Service features you get and how much you pay for the plan.
- Shared ๐ฐ : It allocate
CPU quotas
to each app that runs on theshared VM
, and the resources cannot scale out. - Dedicated ๐ฐ๐ฐ: Only apps in the same
App Service plan
share the same compute resources ondedicated VM
. The higher the tier, the more VM instances are available to you for scale-out. - Isolated ๐ฐ๐ฐ๐ฐ๐ฐ: Your apps run
dedicated Azure VMs
ondedicated Azure VNets
. It provides network isolation on top of compute isolation to your apps. It provides the maximum scale-out capabilities.
WebApps¶
- Containerization: You can publish using code or docker container
- Multiple runtimes:We can choose runtime stack as .NET, Java, Node.js, PHP, and Python on Windows/Linux.
Backup App service¶
There are two types of backups in App Service.
Automatic backups
made for your app regularly as long as it's in a supported pricing tier.Custom backups
require initial configuration, and can be made on-demand or on a schedule.
How backups are stored?
After you have made one or more backups for your app, the backups are visible on the Containers
page of your storage account
, and your app. In the storage account, each backup consists of a .zip
file that contains the backup data and an .xml
file that contains a manifest of the .zip
file contents. You can unzip and browse these files if you want to access your backups without actually performing an app restore.
Remember difference in different backups
-
You need a
Recovery Service Vault
if you want to backup VMs, File Shares, SAP HANA in a VM or SQL Server in a VM. -
You need a
Backup Vault
if you want to backup Azure Disks, Azure Blobs or Azure Database for PostgreSQL Server. -
To backup
App Service
,you need a storage account. Choose your backup destination by selecting a Storage Account and Container. The storage account must belong to the same subscription as the app you want to back up. If you wish, you can create a new storage account or a new container in the respective pages.
Partial backup¶
Partial backups are supported for custom backups
(not for automatic backups
). Sometimes you don't want to back up everything on your app.
To exclude folders and files from being stored in your future backups, create a _backup.filter
file in the %HOME%\site\wwwroot
folder of your app. Specify the list of files and folders you want to exclude in this file.