Skip to content

Latest commit

 

History

History
158 lines (90 loc) · 2.26 KB

README.md

File metadata and controls

158 lines (90 loc) · 2.26 KB



Azure Resource Inventory Automation Account v4



This section explain how to create an Automation Account to run Azure Resource Inventory automatically.



What is required to run ARI as an Automation Account?



1) Azure Automation Account

2) Azure Storage Account

3) Azure Blob Container inside the Storage Account



Once you have created the Automation Account, Storage Account and Blob Container.

Those are the steps you have to do:



On the Automation Account, enable the System Assigned Identity:





This will create an identity in the Entra ID.

Now we are going to use that identity to give the following permissions to the Automation Account:

1) Reader in the Management Group (for the script to be able to read all resources from Azure):





2) Storage Blob Data Contributor to the Storage Account





Now, back in the Automation Account, the following Modules need to be imported with Runtime 7.2:

1) "AzureResourceInventory"

2) "ImportExcel"

3) "Az.ResourceGraph"

4) "ThreadJob"



This is done by going to the "Modules" then "Browse gallery":





Now just create a Powershell Runbook:





Then just add the "Invoke-ARI" command line inside the runbook.


The line must contain the following parameters:

-TenantID
-SkipDiagram
-SkipAPIs
-Automation
-StorageAccount
-StorageContainer

The parameter "StorageAccount" is used to inform the Storage Account where the report will be placed and the "StorageContainer" parameter is used to pass the container within that Storage Account where the report will be placed.



Hit Save and Publish and you are ready to go.