ResourceModules icon indicating copy to clipboard operation
ResourceModules copied to clipboard

Microsoft.Network/networkInterfaces - Default ‘ipConfiguration’ names by default

Open MariusStorhaug opened this issue 3 years ago • 0 comments

Description

Microsoft.Network/networkInterfaces, has an ipConfiguration property. Each configuration requires a name. This is not automated in current version.

The backtrack:

  • VM calls the nested NIC template: https://github.com/Azure/ResourceModules/blob/main/arm/Microsoft.Compute/virtualMachines/deploy.bicep#L333

  • This uses a nicConfiguration object from an array: https://github.com/Azure/ResourceModules/blob/main/arm/Microsoft.Compute/virtualMachines/deploy.bicep#L109

  • So, this requires the parameters, such as: https://github.com/Azure/ResourceModules/blob/main/arm/Microsoft.Compute/virtualMachines/.parameters/windows.parameters.json#L76

Suggestion: Check all resources where we define ipConfiguration. (NetworkInterface primarily) Generate the ipConfigurationName a default value automatically. Still able to override with param/property.

MariusStorhaug avatar Apr 13 '22 06:04 MariusStorhaug