Quantcast
Channel: Azure Virtual Machines forum
Viewing all articles
Browse latest Browse all 12545

Deploying a Custome Managed Image With An ARM Template - however the linked subscription 'subscriptions' was not found.

$
0
0

I am currently tring to deploy VM's using an ARM template and a custom VM image captured using the instruction found here. If I run the script as below it fails to deploy the VM's with the following error

'The client has permission to perform action 'Microsoft.Resources/subscriptions/<subscriptionID>/VMImages/Microsoft.Compute/read' on scope '/subscriptions/<subscriptionID>/resourcegroups/Dev-rg/providers/Microsoft.Compute/virtualMachines/DEPTESTCL1', however the linked subscription 'subscriptions' was not found. "'

If I hard code the subscription Id the deployment completes and the VM's are created. I have full permission to the Azure subscription (Owner) and there are no restrictions in place. What am I doing wrong?

I do not want to hard code the subscription ID a this template will be stored in Github

The issue seems to be here

"storageProfile": {"osDisk": {"name": "[concat(variables('vmNamePrefix'), copyIndex(1), '-osdisk')]","createOption": "FromImage","managedDisk": {"storageAccountType": "[parameters('osDiskType')]"
            }
          },"imageReference": {"id": "[concat('/subscriptions/', variables('subscriptionId'), '/resourceGroups/VMImages/providers/Microsoft.Compute/images', variables('operatingSystemValues')[parameters('operatingSystem')].imageValue)]"
          }
        },



Viewing all articles
Browse latest Browse all 12545

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>