Skip to content

intel/terraform-intel-azure-app-service-plan

Intel Logo

Intel® Optimized Cloud Modules for Terraform

© Copyright 2024, Intel Corporation

Azure App Service Plan Module

This module can be used to deploy an Intel optimized Azure Service Plan.

The module favors V3 Premium instances which run on faster processors.

Usage

See examples folder for complete examples.

By default, you only have to pass two variables

service_plan_name
resource_group_name      

main.tf

module "linux-service-plan" {
  source              = "intel/azure-app-service-plan/intel"
  service_plan_name   = "intel-linux-service-plan-01"
  resource_group_name = "my-app-rg"
}

Run Terraform

terraform init  
terraform plan
terraform apply 

Considerations

This module does not deploy the App Service Web App, for that look at the Intel Windows/Linux App Service Web App modules.

Requirements

Name Version
terraform >=1.3.0
azurerm ~>3.86

Providers

Name Version
azurerm ~>3.86

Modules

No modules.

Resources

Name Type
azurerm_service_plan.service_plan resource
azurerm_resource_group.rg data source

Inputs

Name Description Type Default Required
app_service_environment_id If ASE is used, enter the ID of the App Service Environment string null no
maximum_elastic_worker_count If Azure Function Elastic plan is used. The maximum number of total workers allowed for this ElasticScaleEnabled App Service Plan number null no
os_type The operating system type of the App Service Plan: 'Windows', 'Linux' or 'WindowsContainer' string "Linux" no
per_site_scaling_enabled Should the App Service Plan scale per application or per worker bool false no
resource_group_name The name of the Resource Group string n/a yes
service_plan_name The name of the App Service Plan string n/a yes
sku_name The SKU of the App Service Plan string "P2v3" no
tags Map of tags to apply map(string) null no
worker_count The number of workers associated with this App Service Plan number null no
zone_balancing_enabled Should the App Service Plan use zone balancing bool true no

Outputs

Name Description
app_service_environment_id If ASE is used, enter the ID of the App Service Environment
id The ID of the App Service Plan
kind The kind of the App Service Plan. True if os_type is Linux, otherwise false.
location The location of the App Service Plan
maximum_elastic_worker_count If Azure Function Elastic plan is used. The maximum number of total workers allowed for this ElasticScaleEnabled App Service Plan
name The name of the App Service Plan
os_type The operating system type of the App Service Plan: 'Windows', 'Linux' or 'WindowsContainer'
per_site_scaling_enabled Should the App Service Plan scale per application or per worker
reserved Is the App Service Plan reserved
resource_group_name The name of the Resource Group
sku_name The SKU of the App Service Plan
tags Map of tags
worker_count The number of workers associated with this App Service Plan
zone_balancing_enabled Should the App Service Plan scale per application or per worker