makeporngreatagain.pro
yeahporn.top
hd xxx

How to find Unused Amazon EC2 Security groups

2,227
  • You would need to setup AWS CLI for getting the list of Unused Amazon EC2 Security groups
  • First, get a list of all security groups
     aws ec2 describe-security-groups --query 'SecurityGroups[*].GroupId' --output text | tr '\t' '\n'
  • Then get all security groups tied to an instance, then piped to sort then uniq:
    aws ec2 describe-instances --query 'Reservations[*].Instances[*].SecurityGroups[*].GroupId' --output text | tr '\t' '\n' | sort | uniq
  • Then put it together and compare the 2 lists and see what’s not being used from the master list:
    comm -23 <(aws ec2 describe-security-groups --query 'SecurityGroups[*].GroupId' --output text | tr '\t' '\n'| sort) <(aws ec2 describe-instances --query 'Reservations[*].Instances[*].SecurityGroups[*].GroupId' --output text | tr '\t' '\n' | sort | uniq)
Leave A Reply

Your email address will not be published.

baseofporn.com https://www.opoptube.com
Ads Blocker Image Powered by Code Help Pro

Ads Blocker Detected!!!

We have detected that you are using extensions to block ads. Please support us by disabling these ads blocker.