Azure Azure - Terraform templates

App Service Plan

Last updated: December 16, 2024
App Service Plans serve as containers for WebApps. App Service Plan defines the operating system and the pricing plan you run your WebApps on. 

You can create a windows (or linux) AppServicePlan using the snippet below:
resource "azurerm_service_plan" "appserviceplan" {
  name                = "${var.environment_prefix}-${var.solution_prefix}${var.customer_prefix}-appserviceplan"
  location            = local.location
  resource_group_name = azurerm_resource_group.rg.name
  os_type             = "Windows"
  sku_name = "S1"
  tags = local.tags
}

Note: Check out the documentation for other options and plans

Further reading