Created
September 24, 2019 17:17
-
-
Save CodeFreezr/764fe708efc8cc69acb493a7d14bc941 to your computer and use it in GitHub Desktop.
Count the ebs volumes and the amount of Gigabytes per state.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
aws ec2 describe-volumes | jq -r '.Volumes | [ group_by(.State)[] | { (.[0].State): ([.[].Size] | add) } ] | add' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment