I\'ve got two Azure Function apps that use deployment slots, stage and production. These two Azure Function apps have about 50~ key:value pairs in Application Settings to de
It is possible to combine static configuration with deployment-time references.
You use the union
template function to combine your static configuration (object or array) with some deployment-time value that you wrap using the json
template function.
I use this to set Application Insights at deployment-time with a base config object and a app service-specific object (broken up for easier reading):
[union(
variables('appServiceBaseConfig'),
variables('appService1'),
json(
concat(
'{\"APPINSIGHTS_INSTRUMENTATIONKEY\":\"',
reference(concat('microsoft.insights/components/', variables('applicationInsightsName')), '2015-05-01').InstrumentationKey,
'\"}')
)
)
]