Azure / Azure/PSRule.Rules.Azure
Upgrade Node Functions to 14 or greater
- Dominant language
- PowerShell
- Stars
- 447
- Forks
- 109
- Avg merge
- 2d 19h
- Merged PRs (30d)
- 23
Description
# Rule request
## Suggested rule change
Add a new rule `Azure.Function.NodeVersion` to configure a minimum version of node.js with Azure Functions. Also host version `~4` is required.
Only applies to Azure Functions sites with:
- `FUNCTIONS_WORKER_RUNTIME` set to `node`
The selector `Azure.AppService.IsFunctionApp` can be used to only target function apps.
Rule recommendation will be similar to:
- https://azure.github.io/PSRule.Rules.Azure/en/rules/Azure.AppService.NETVersion/
- https://azure.github.io/PSRule.Rules.Azure/en/rules/Azure.AppService.PHPVersion/
## Applies to the following
The rule applies to the following:
- Resource type: **Microsoft.Web/sites** and **Microsoft.Web/sites/slots**
## Additional context
- [[Upgrading your Azure Function Apps to run on PowerShell 7.2](https://github.com/Azure/azure-functions-powershell-worker/wiki/Upgrading-your-Azure-Function-Apps-to-run-on-PowerShell-7.2)](https://learn.microsoft.com/azure/azure-functions/functions-reference-node#setting-the-node-version)
Contributor guide
Assessment
This issue has not been assessed yet.