Last active
August 29, 2015 14:09
-
-
Save dannyfallon/79dd7b40ebcb1b574844 to your computer and use it in GitHub Desktop.
PUBLIC GIST: AWS CLI Magic Fu
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
# List all access keys for every IAM user | |
aws iam list-users | jq '.Users[].UserName' | sed "s/\"//g" | xargs -I {} aws iam list-access-keys --user={} | |
# Enable Metrics Collection on ASGs that don't have it | |
aws autoscaling describe-auto-scaling-groups | jq '.AutoScalingGroups[] | select(.EnabledMetrics==[]).AutoScalingGroupName' | xargs -I {} aws autoscaling enable-metrics-collection --auto-scaling-group-name {} --granularity "1Minute" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment