This sample contains a script to easily migrate template gallery templates to templateSpec resources.
{"type": "microsoft.resources/deployments", "apiversion": "2020-10-01", "name": "createvnet", "properties": {"mode": "incremental", "templatelink": {"uri": "[variables('vnettemplateuri')]", "contentversion": "1.0.0.0"}, "parameters": {"virtualnetworkname": {"value": "[variables('virtualnetworkname')]"}, "virtualnetworkaddressrange": {"value": "[variables('virtualnetworkaddressrange')]"}, "subnetname": {"value": "[variables('adsubnetname')]"}, "subnetrange": {"value": "[variables('adsubnet')]"}, "location": {"value": "[parameters('location')]"}}}} 