Skip to content

Instantly share code, notes, and snippets.

@myugan
Created August 9, 2021 03:36
Show Gist options
  • Save myugan/a075717d19839b0fd7ac3c5893896c7a to your computer and use it in GitHub Desktop.
Save myugan/a075717d19839b0fd7ac3c5893896c7a to your computer and use it in GitHub Desktop.

Revisions

  1. myugan created this gist Aug 9, 2021.
    10 changes: 10 additions & 0 deletions get_public_ebs.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,10 @@
    #!/bin/bash

    keyword="any_description_here"

    regions=( us-east-1 us-east-2 us-west-1 us-west-2 ap-south-1 ap-northeast-3 ap-northeast-2 ap-southeast-1 ap-southeast-2 ap-northeast-1 ca-central-1 eu-central-1 eu-west-1 eu-west-2 eu-west-3 eu-south-1 )
    for i in "${regions[@]}"
    do
    echo -n "Region: ${i}"
    aws ec2 describe-snapshots --region ${i} --filters "Name=description,Values=$keyword"
    done