turbot/aws_insights

Query: ec2_instance_public_access

Usage

powerpipe query aws_insights.query.ec2_instance_public_access

Steampipe Tables

SQL

select
'Public IP Address' as label,
case when public_ip_address is null then 'Disabled' else host(public_ip_address) end as value,
case when public_ip_address is null then 'ok' else 'alert' end as type
from
aws_ec2_instance
where
account_id = split_part($1, ':', 5)
and region = split_part($1, ':', 4)
and arn = $1;

Dashboards

The query is used in the dashboards: