Pipe multiple resource groups #71
-
I noted that this has the ability to diagram multiple resource groups, but can we pipe in a list using a CSV file for example? The company I just started had very bad azure engineers and created resource groups for each resource individually. So every service, is within its own resource group. I have a list of the resources, but rather than type all those out in one long script, I was hoping there was an ability to let the script pull the groups from a file instead. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
I actually got it to work but getting an error. I first created the csv using this:
Then imported the CSV as a function:
Then ran the command like this:
But received the following error:
Any help would be great! |
Beta Was this translation helpful? Give feedback.
-
This issue has been resolved. Ensuring the use the property name within the CSV fixed this. So the command would be:
Where ResourceGroupName is the property value in the exported CSV file. |
Beta Was this translation helpful? Give feedback.
This issue has been resolved. Ensuring the use the property name within the CSV fixed this. So the command would be:
Export-AzViz -ResourceGroup $rsglist.ResourceGroupName -Theme dark -OutputFormat png -Show
Where ResourceGroupName is the property value in the exported CSV file.