turbot/aws_insights

Query: ec2_instance_network_interfaces

Usage

powerpipe query aws_insights.query.ec2_instance_network_interfaces

Steampipe Tables

SQL

select
p ->> 'NetworkInterfaceId' as "Network Interface ID",
p ->> 'InterfaceType' as "Interface Type",
ips -> 'Association' ->> 'PublicIp' as "Public IP Address",
ips ->> 'PrivateIpAddress' as "Private IP Address",
p ->> 'Status' as "Status",
p ->> 'SubnetId' as "Subnet ID",
p ->> 'VpcId' as "VPC ID"
from
aws_ec2_instance,
jsonb_array_elements(network_interfaces) as p,
jsonb_array_elements(p -> 'PrivateIpAddresses') as ips
where
region = split_part($1, ':', 4)
and account_id = split_part($1, ':', 5)
and arn = $1;

Dashboards

The query is used in the dashboards: