Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

azurerm health_check_path not registering / health_check still disabled #13772

Closed
christie-flacco opened this issue Oct 18, 2021 · 8 comments
Closed

Comments

@christie-flacco
Copy link

Community Note

  • 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

Terraform (and AzureRM Provider) Version

Using Terraform v0.14.8

Affected Resource(s)

hashicorp/azurerm

Terraform Configuration Files

# Azure Provider
provider "azurerm" {
  skip_provider_registration = true
  features {}
}

# Configure remote storage of our Terraform state in Azure
terraform {
  required_providers {
    azurerm = {
      source  = "hashicorp/azurerm"
      version = ">=2.36.0"
    }
  }
}

resources.tf:
module "XYZ" {
....
web_app = {
    site_config = {
      cors = {
        allowed_origins     = ["*"]
        support_credentials = false
      }
      health_check_path = "/"
    }
...
}

Debug Output

Panic Output

Expected Behaviour

health check in azure should be enabled with the health check path set to what I configured "/"

Actual Behaviour

Health check is disabled

References

@christie-flacco
Copy link
Author

@stephybun can you assist me with this?

@stephybun
Copy link
Member

Hi @christie-altadonna, apologies for the delay. Our SME on app-service is out this week, but I'll see if I can spot what the issue is. It would be helpful if I could reproduce the behaviour on my end, for that I need more info on your terraform config. Could you please provide the full config for the resource you are using after redacting any sensitive information?

@christie-flacco
Copy link
Author

@stephybun Apologies for delay. What info do you need to reproduce? Would like to redact as much as I can.

@adamkwolf
Copy link

Hi @christie-altadonna, apologies for the delay. Our SME on app-service is out this week, but I'll see if I can spot what the issue is. It would be helpful if I could reproduce the behaviour on my end, for that I need more info on your terraform config. Could you please provide the full config for the resource you are using after redacting any sensitive information?

Hi, is there any updates on this?

@stephybun
Copy link
Member

@adamkwolf @christie-altadonna

I would need a minimal TF config that reproduces the undesired behaviour, at the very least I need to know which resource this issue refers to, so e.g.

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

  site_config {
    dotnet_framework_version = "v4.0"
    scm_type                 = "LocalGit"
  }
...
}

sensitive info like secrets/certificates etc. can be redacted.

@adamkwolf
Copy link

@adamkwolf @christie-altadonna

I would need a minimal TF config that reproduces the undesired behaviour, at the very least I need to know which resource this issue refers to, so e.g.

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

  site_config {
    dotnet_framework_version = "v4.0"
    scm_type                 = "LocalGit"
  }
...
}

sensitive info like secrets/certificates etc. can be redacted.

module "" {
  source      = ""
  environment = "prod"
  location    = var.location
  name        = var.app_name
  vault_id    = data.azurerm_key_vault.kv.id

  asp = {
    sku = {
      tier = var.asp_tier
      size = var.asp_size
    }
  }

  autoscale = {
    capacity_def = var.autoscale_min
    capacity_min = var.autoscale_min
    capacity_max = var.autoscale_max
  }

  web_app = {
    site_config = {
      cors = {
        allowed_origins     = ["*"]
        support_credentials = false
      }
      health_check_path = "/"
    }

    app_settings = {}
  }
}

@jackofallops
Copy link
Member

Hi @adamkwolf / @christie-altadonna - I'm afraid the module details provided don't show us which resource(s) are used. We don't need any sensitive details, but to diagnose what's going on we do need to know which resource that data is being passed to, and any supporting information on the resource that's relevant (e.g. OS Type). I'm guessing from the partial configs it's going to be azurerm_app_service? Whilst this resource is still available in 3.0, it is now deprecated and feature-frozen, so no longer receiving bug-fixes or enhancements in order to maintain compatibility, and there are no further 2.x releases planned.

I'd recommend looking into moving to the replacement resources azurerm_windows_web_app and azurerm_linux_web_app introduced in 3.0 as appropriate for your configuration, which will be receiving enhancements and updates going forward.

I'm going to close this out for now, however, if I'm mistaken and the problem isn't in one of the deprecated resources, we can of course re-open.

Thanks!

@github-actions
Copy link

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 27, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants