Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Adds a script to get all vm sizes #338

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions scripts/get-all-avaible-vm-sizes.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# You have to install the Az Modules with the following commands:
# `Install-Module Az`
# `Import-Module Az`
# Also make sure, that you already did an authentication!

$locations = Get-AzLocation
$vmSizes = [System.Collections.Generic.HashSet[string]]@()
foreach ($location in $locations.Location) {
$vmSizeNames = (Get-AzVMSize -Location $location).Name
foreach ($name in $vmSizeNames) {
$vmSizes.Add($name)
}
}

Write-Output $vmSizes
Loading