turbot/gcp_insights

Query: compute_instance_public_access

Usage

powerpipe query gcp_insights.query.compute_instance_public_access

Steampipe Tables

SQL

select
'Public Access' as label,
case
when d ->> 'natIP' is not null then 'Enabled'
else 'Disabled'
end as value,
case
when d ->> 'natIP' is not null then 'alert'
else 'ok'
end as type
from
gcp_compute_instance,
jsonb_array_elements(network_interfaces) nic,
jsonb_array_elements(nic -> 'accessConfigs') d
where
id = $1;

Dashboards

The query is used in the dashboards: