turbot/gcp_insights

Query: compute_subnets_for_kubernetes_cluster

Usage

powerpipe query gcp_insights.query.compute_subnets_for_kubernetes_cluster

SQL

select
s.id::text || '/' || s.project as subnetwork_id
from
gcp_kubernetes_cluster c,
gcp_compute_subnetwork s
where
c.id = split_part($1, '/', 1)
and s.self_link like '%' || (c.network_config ->> 'Subnetwork') || '%'
and c.project = split_part($1, '/', 2);