Skip to content

Instantly share code, notes, and snippets.

@chgeuer
Created October 16, 2017 13:21
Show Gist options
  • Save chgeuer/afc98e6d6cd442f001853b581d9be562 to your computer and use it in GitHub Desktop.
Save chgeuer/afc98e6d6cd442f001853b581d9be562 to your computer and use it in GitHub Desktop.
show-vm-sizes.sh
for location in $(az account list-locations | jq -r ".[].name"); do
az vm list-sizes -l $location | jq -r "{ \"$location\": [ .[].name ] }" > "${location}.json"
echo "Wrote ${location}.json"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment