hashicorp / terraform-provider-azurerm

Terraform provider for Azure Resource Manager
https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs
Mozilla Public License 2.0
4.52k stars 4.6k forks source link

Feature Request: In App Services (Web Apps) provide ability to set Certificate exclusion paths #8876

Open ghost opened 3 years ago

ghost commented 3 years ago

Community Note

Description

In Azure App Services (Web Apps), please provide ability to set Certificate exclusion paths. This allows our Azure Traffic Manager Endpoint to communicate to our Web Apps without a certificate for health check endpoints. Here is a screenshot from the Azure portal: image Here is an excerpt from the Azure App Service (Web App) Export Template: "clientCertExclusionPaths": "/foo;/bar;/hello;/world", Here is an example Azure CLI command that I tested out: az webapp update --set clientCertExclusionPaths="/foo;/bar;/hello;/world" --name myWebapp --resource-group myResourceGroup

Note that the current work around my group uses to automate this setting is to use the above mentioned azure cli command after applying Terraform. Also we prefer to avoid using the ARM templates deployment resource script as much as possible. Thanks.

New or Affected Resource(s)

Potential Terraform Configuration

resource "azurerm_app_service" "example" {
  name                = "example-app-service"
  location            = azurerm_resource_group.example.location
  resource_group_name = azurerm_resource_group.example.name
  app_service_plan_id = azurerm_app_service_plan.example.id

  client_affinity_enabled = false
  client_cert_enabled = true
  client_cert_exclusion_paths =  "/foo;/bar;/hello;/world"  # This is the property setting to add the certificate exclusion paths.

  app_settings = {
    "SOME_KEY" = "some-value"
  }
}

References

Below is a similar issue but for function apps only:

Related documentation below:

kiazhi commented 3 years ago

azurerm_function_app needs something similar too.