Creating an AWS VPC community stock report utilizing PowerShell generally is a highly effective technique to handle and audit your AWS infrastructure. On this weblog I’m sharing a pattern code of PowerShell that can be utilized to get the VPC stock report from AWS.
Logic is to imagine function, go through every area and account to search out the VPC throughout entire AWS group.
This answer is one other addition to the scripts that I’ve already shared for various AWS merchandise:
AWS | Search Outcomes | Tech Wizard
Conditions for this Resolution:
Obtain the script from Git or PowerShell gallery from under hyperlinks:
Git:
https://github.com/VikasSukhija/Downloads
AWSVPCInventory.ps1
PowerShell Gallery:
https://www.powershellgallery.com/packages/AWSVPCInventory
Set up-Script -Title AWSVPCInventory
Replace the under part of the script with your individual parameters:

This script wants entry and secret key of the account that may assume a task that has entry to learn the VPC networks info throughout the entire group.
Please safe the entry key and secret key as encrypted if you’ll schedule this script in manufacturing.
Script will fetch under particulars for every VPC subnets.

Replace the Tag code as per Your setting.
Right here is the E-mail that e-mail tackle talked about in variable will obtain.

Right here is the CSV report that your will get:

Notice: modify the AccountID for authentication as per your group at line 68, Line 106, Line 110, Line115, Line 117.

I consider this PowerShell script will help you in producing the VPC report on your AWS occasion.
Thanks for studying and downloading…
Tech Wizard
https://techwizard.cloud