Skip to content

Instantly share code, notes, and snippets.

@florin-andrei-curbside
Created February 28, 2017 20:08
Show Gist options
  • Save florin-andrei-curbside/5b4ae54e71f6786c5146eccd3a7d3930 to your computer and use it in GitHub Desktop.
Save florin-andrei-curbside/5b4ae54e71f6786c5146eccd3a7d3930 to your computer and use it in GitHub Desktop.
how to list S3 buckets locations
aws s3api list-buckets --output text | awk '{print $3}' > buckets.txt
for b in `cat buckets.txt`; do echo -ne "$b\t"; aws s3api get-bucket-location --bucket $b --output text; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment