turbot/gcp_insights

Query: compute_autoscalers_for_compute_instance_group

Usage

powerpipe query gcp_insights.query.compute_autoscalers_for_compute_instance_group

SQL

select
a.id::text as autoscaler_id
from
gcp_compute_instance_group g,
gcp_compute_autoscaler a
where
g.name = split_part(a.target, 'instanceGroupManagers/', 2)
and g.id = (split_part($1, '/', 1))::bigint
and g.project = split_part($1, '/', 2);