I am trying to create a NIC for a VM in a resource group. The problem I have is that i'm trying to reference a subnet from another resource group in Azure. Therefore, I am having to reference it using subscription level deployments in ARM templates.
"subnetref": "[concat(subscription().id, '/resourceGroups/', parameters('HUB Network RG'), '/providers/Microsoft.Network/virtualNetworks/', parameters('HUB VNet'), '/virtualNetworks/subnets', parameters('HUB DC Subnet'))]"
Run Code Online (Sandbox Code Playgroud)
Above is the subnet ref variable I am trying to create. I then have the below for the VM NIC i'm …