PSRule.Rules.Azure
PSRule.Rules.Azure copied to clipboard
Upgrade Node Functions to 14 or greater
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_RUNTIMEset tonode
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://learn.microsoft.com/azure/azure-functions/functions-reference-node#setting-the-node-version)