terraform-provider-azurerm icon indicating copy to clipboard operation
terraform-provider-azurerm copied to clipboard

Add support for app_service_plan_id in Windows/Linux slot resources

Open NikRimington opened this issue 3 years ago • 0 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Community Note

  • Please vote on this issue by adding a :thumbsup: reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

The azurerm_windows_web_app_slot and azurerm_linux_web_app_slot are designed to replace the azurerm_app_service_slot however they both appear to be missing a useful bit of functionality. They do not allow for slots to be created against different service plans than the main web app.

The legacy resource had the following option app_service_plan_id which meant that your slot's app service plan could differ from the main web apps. It would be great to see this added back in.

New or Affected Resource(s)/Data Source(s)

azurerm_windows_web_app_slot, azurerm_linux_web_app_slot

Potential Terraform Configuration

resource "azurerm_windows_web_app_slot" "example" {
  name            = "example-slot"
  app_service_id  = azurerm_windows_web_app.example.id
  service_plan_id = azurerm_app_service_plan.alternate-plan.id

  site_config {}
}

References

No response

NikRimington avatar Aug 11 '22 13:08 NikRimington