-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Function App application stack setting dotnet_version does not control dotnet version of the Function App #16927
Comments
Additional info: running "az functionapp config set --net-framework-version "v6.0" --name --resource-group " post-deployment fixed my problem, and ib subsequent plan/apply this goes untouched. |
I confirm this, also tested it with azurerm 3.6 and eventually 3.1 with same result as described above |
@ASPCKenneth - yes and no . . . Yes because that is true, and no because the azurerm_function_app is deprecated and won't be supported in 4.0, so I'm assuming that azurerm_windows_function_app and azurerm_linux_function_app are its replacements that should have feature parity. |
@SteveKurutz The function v4.0 requires .NET6.0 runtime. I will check the relevant properties to see if there is a better way to implement the feature. |
Thanks @xiaxyi . This looks on the surface like wires got crossed in the new resource type. The desired outcome is to be able to set .NET to 6. However that gets done in AzureRM is fine by me. |
FYI `resource "null_resource" "netfx" { provisioner "local-exec" { |
This looks like a duplicate of 16417. |
@SteveKurutz The issue should be fixed now, can you confirm if the app stack is set correcly for your windows dotnet function app now? |
Thanks for taking the time to submit this issue. It looks like this has been resolved as of #19685. As such, I am going to mark this issue as closed. |
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. |
Is there an existing issue for this?
Community Note
Terraform Version
1.9
AzureRM Provider Version
3.7.0
Affected Resource(s)/Data Source(s)
azurerm_windows_function_app
Terraform Configuration Files
Debug Output/Panic Output
Expected Behaviour
using azurerm 2.7 function app code with site_config dotnet_framework_version = "v6.0", I get:
"netFrameworkVersion": "v6.0",
... and there's no mention of windowsFxVersion.
Actual Behaviour
Resulting Function app gets this configuration (ARM exported because UI hides this):
"netFrameworkVersion": "v4.0",
If I go against what documentation says and include the FUNCTIONS_WORKER_RUNTIME app setting, then I also get the following, which doesn't appear to help.
"windowsFxVersion": "DotNet|6",
Steps to Reproduce
Important Factoids
Trying to deploy new resources using 3.x to avoid resource types that will be deprecated in 4.x.
References
Documentation at https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/windows_function_app states about the application_stack block: "If this is set, there must not be an application setting FUNCTIONS_WORKER_RUNTIME.". This problem occurs both with and without the FUNCTIONS_WORKER_RUNTIME app setting present. Even when I deploy without FUNCTIONS_WORKER_RUNTIME in my code, Azure adds it to the settings automatically.
The text was updated successfully, but these errors were encountered: