03 - Configuration (Dedicated)¶
Manage app settings, connection strings, and PowerShell module dependencies for your Dedicated (App Service Plan) app.
App Settings¶
az functionapp config appsettings set \
--name $APP_NAME \
--resource-group $RG \
--settings "GreetingPrefix=Hello" "FUNCTIONS_WORKER_RUNTIME_VERSION=7.4"
az functionapp config appsettings set | Add or update application settings on the function app. | | --name | Name of the function app. | | --resource-group | Resource group that contains the function app. | | --settings | Key=value application settings to apply. | Read settings in PowerShell with $env:GreetingPrefix.
Module Dependencies¶
Use managed dependencies. Declare modules in requirements.psd1 and enable managedDependency in host.json:
The runtime downloads them from the PowerShell Gallery on startup.
Verification¶
| Command/Parameter | Purpose | | --- | --- | |az functionapp config appsettings list | List the application settings on the function app. | | --name | Name of the function app. | | --resource-group | Resource group that contains the function app. | | --output | Output format (table). | Confirm GreetingPrefix appears with the expected value.
Next Steps¶
With configuration in place, wire up observability.
See Also¶
- Tutorial Overview & Plan Chooser
- PowerShell Language Guide
- Platform: Hosting Plans
- Operations: Deployment
- Recipes Index