code-dumps/aws/aws-config-status.sh

10 lines
547 B
Bash
Raw Normal View History

2024-02-22 15:37:33 +08:00
#!/bin/bash
# Check config recorder status in all regions
aws --region=us-east-1 ec2 describe-regions --query Regions[].RegionName --output text | sed -e 's/\t/\n/g' | while read r; do
echo "$r"
echo "Recorder on: $(aws --region $r configservice describe-configuration-recorder-status --query ConfigurationRecordersStatus[].recording --output text)"
echo "Recording global resources: $(aws --region $r configservice describe-configuration-recorders --query ConfigurationRecorders[].recordingGroup.includeGlobalResourceTypes --output text)"
done