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_windows_function_app appsetting WEBSITE_NODE_DEFAULT_VERSION is added in every apply even if the function app has the value set #17198

Closed
1 task done
Ikriva opened this issue Jun 10, 2022 · 3 comments · Fixed by #18014
Milestone

Comments

@Ikriva
Copy link

Ikriva commented Jun 10, 2022

Is there an existing issue for this?

  • I have searched the existing issues

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 Version

1.1.9

AzureRM Provider Version

3.10.0

Affected Resource(s)/Data Source(s)

azurerm_windows_function_app

Terraform Configuration Files

terraform {
  required_providers {
    azurerm = {
      source  = "hashicorp/azurerm"
      version = "~> 3.10"
    }
  }
  required_version = ">= 1.1.9"
}

provider "azurerm" {
  features {}
  tenant_id       = var.tenant_id
  subscription_id = var.subscription_id
}

resource "azurerm_resource_group" "default" {
  name     = "error-testing-rg"
  location = "westeurope"
  tags     = var.default_tags
}

resource "azurerm_storage_account" "function_app" {
  name                            = "errortesting"
  resource_group_name             = azurerm_resource_group.default.name
  location                        = azurerm_resource_group.default.location
  account_tier                    = "Standard"
  account_replication_type        = "LRS"
  min_tls_version                 = "TLS1_2"
  allow_nested_items_to_be_public = false
}

resource "azurerm_service_plan" "default" {
  name                         = "error-testing-plan"
  location                     = azurerm_resource_group.default.location
  resource_group_name          = azurerm_resource_group.default.name

  os_type                      = "Windows"
  sku_name                     = "Y1"
}

resource "azurerm_windows_function_app" "default" {
  name                        = "error-testing-func"
  location                    = azurerm_resource_group.default.location
  resource_group_name         = azurerm_resource_group.default.name
  service_plan_id             = azurerm_service_plan.default.id
  storage_account_name        = azurerm_storage_account.function_app.name
  storage_account_access_key  = azurerm_storage_account.function_app.primary_access_key
  functions_extension_version = "~4"
  https_only                  = true

  app_settings = {
    FUNCTIONS_WORKER_RUNTIME       = "node"
    WEBSITE_NODE_DEFAULT_VERSION   = "~16"
  }

  site_config {
    
  }
}

Debug Output/Panic Output

https://gist.github.com/Ikriva/7c2be9a25d4e0a81656fc55f2fe46145

Expected Behaviour

On second terraform apply, there should be no changes to be applied.

Actual Behaviour

Capture

Steps to Reproduce

terraform apply x2

Important Factoids

No response

References

No response

@Ikriva Ikriva added the bug label Jun 10, 2022
@github-actions github-actions bot removed the bug label Jun 10, 2022
@xiaxyi
Copy link
Contributor

xiaxyi commented Jun 21, 2022

@jackofallops I noticed the note in the code and suggesting the node version is being collected from the property windowsFxVersion, however, just would like to know why didn't we set the property back in app setting, is there any conflict with the windowsFxVersion?

@github-actions
Copy link

This functionality has been released in v3.19.0 of the Terraform Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

@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 Sep 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
4 participants