Azure / Azure/arm-template-whatif

Field identity is ignored for the resource type Microsoft.Web/sites

Open
#124 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
HTML
Stars
101
Forks
21
Avg merge
3h 35m
Merged PRs (30d)
1

Description

Hello,

if you create an Azure function or an App Service without Managed Identity and you launch the ARM Template what if to create it, you won't be prompt to enable it.

Sample code
`
{
"type": "Microsoft.Web/sites",
"apiVersion": "2019-08-01",
"name": "[parameters('appName')]",
"location": "[parameters('location')]",
"tags": "[union(variables('additional_tags'),resourceGroup().tags)]",
"kind": "[parameters('appKind')]",
"identity": {
"type": "SystemAssigned"
},
"properties": {
"serverFarmId": "[concat(main.getResource('Microsoft.Web/serverfarms',parameters('hostingPlanSubscriptionId'), parameters('hostingPlanResourceGroupName'),parameters('hostingPlanName')).id)]",
"siteConfig": {
"appSettings": "[variables('appSettings')]",
"http20Enabled": true,
"localMySqlEnabled": false,
"netFrameworkVersion": "v4.0",
"use32BitWorkerProcess": "false",
"scmType": "VSTSRM",
"alwaysOn": "[parameters('alwaysOn')]",
"cors": "[if(equals(length(parameters('allowedOrigins')),0), json('null'),variables('cors'))]"
},
"clientAffinityEnabled": "false"
},
`

Sample result
image

Regards,
James

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the Microsoft.Web/sites ARM template in the issue and reproduce the what-if result for an Azure Function or App Service with the shown SystemAssigned identity and without Managed Identity. Trace how the what-if output handles the identity field, then verify that the result prompts to enable the identity when appropriate.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
cloud
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.