Categories
Snippets

jq makes AWS “describe-instances” actually useful

Just so I don’t forget 🙂

aws ec2 describe-instances | \
  jq '.Reservations[].Instances[] | {IP: .PrivateIpAddress, ID: .InstanceId, Name: .Tags[] | select(.Key=="Name").Value}'

 

Leave a Reply

Your email address will not be published. Required fields are marked *