Azure / azure-blueprints

A library of sample Blueprints that can be easily imported via API or PowerShell
MIT License
258 stars 152 forks source link

How one can find out all resources which were deployed as part of Assignment? #31

Closed artisticcheese closed 4 years ago

artisticcheese commented 4 years ago

Hello,

Is there a powershell command which will allow access to individual resources deployed via blueprint (same sort of information available in portal UI on Blueprint assignment page)? Resources which are being deployed are using random names based off SubscriptionID,ResourceGroup as part of ARM template deployment so I need to be able to retrieve resulting name of resource which was deployed into subscription. I can not figure out how to do that. Example I deploy SQL and name is coded as "sqlServerName": "[tolower(concat(parameters('Organization_Name') , uniqueString(subscription().id, resourceGroup().id), '-sqlserver'))]", How do I find out what was the name of sqlServerName from powershell once Blueprint finished assignment?