You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please vote on this issue by adding a 馃憤 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 and review the contribution guide to help.
Terraform Version
1.6.6
AzureRM Provider Version
3.70.0
Affected Resource(s)/Data Source(s)
azurerm_linux_function_app
Terraform Configuration Files
Any config that allows creation of a linux function app.
Debug Output/Panic Output
After this function-app resource is created, subsequent terraform plans always shows this below change, which never gets fixed by a terraform apply.
module.funcs["datagroup"].azurerm_linux_function_app.main["instance"] will be updated in-place
~ resource "azurerm_linux_function_app""main" {
id = "/subscriptions/............"
name = "func-app-xyz"~ tags = {
"category" = "ABC"
}
~ site_config {
~ health_check_eviction_time_in_min = 0 -> 2
# (25 unchanged attributes hidden)# (1 unchanged block hidden)
}
# (1 unchanged block hidden)
}
Expected Behaviour
There should be no change to health_check_eviction_time_in_min planned by terraform.
Actual Behaviour
When health_check is disabled (i.e., not enabled) for a Function App (verify in portal), then the function app's health_check_eviction_time_in_min will be set to 0 by Azure. But the terraform provider wrongly tries to set it to the lowest possible non-zero value, which is 2. This leads to a lingering change in the plan, which cannot be effectively/permanently applied. When this is applied, Azure would change the eviction time back to 0 since health_check is disabled for the function-app. Terraform provider wants to change this 0 to 2 in subsequent terraform-plans. This planned output is displayed even when no change is made to the configuration (code files).
module.funcs["datagroup"].azurerm_linux_function_app.main["instance"] will be updated in-place
~ resource "azurerm_linux_function_app" "main" {
id = "/subscriptions/............"
name = "func-app-xyz"
~ tags = {
"category" = "ABC"
}
Thanks @xiaxyi.
We don't specify set either health_check_eviction_time_in_min or health_check_path when creating the function app. The portal shows that health check is "disabled" for this function app. For disabled health checks, Azure sets the eviction time to 0 minutes, but terraform tries to change that to 2 minutes. The range of 2 to 10 minutes is valid only if the health check is enabled, as can be seen on the portal.
Is there an existing issue for this?
Community Note
Terraform Version
1.6.6
AzureRM Provider Version
3.70.0
Affected Resource(s)/Data Source(s)
azurerm_linux_function_app
Terraform Configuration Files
Any config that allows creation of a linux function app.
Debug Output/Panic Output
Expected Behaviour
There should be no change to health_check_eviction_time_in_min planned by terraform.
Actual Behaviour
When health_check is disabled (i.e., not enabled) for a Function App (verify in portal), then the function app's health_check_eviction_time_in_min will be set to 0 by Azure. But the terraform provider wrongly tries to set it to the lowest possible non-zero value, which is 2. This leads to a lingering change in the plan, which cannot be effectively/permanently applied. When this is applied, Azure would change the eviction time back to 0 since health_check is disabled for the function-app. Terraform provider wants to change this 0 to 2 in subsequent terraform-plans. This planned output is displayed even when no change is made to the configuration (code files).
module.funcs["datagroup"].azurerm_linux_function_app.main["instance"] will be updated in-place
~ resource "azurerm_linux_function_app" "main" {
id = "/subscriptions/............"
name = "func-app-xyz"
~ tags = {
"category" = "ABC"
}
Steps to Reproduce
Important Factoids
No response
References
https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/linux_function_app
The text was updated successfully, but these errors were encountered: