turbot/alicloud_insights

Query: ecs_snapshots_for_kms_key

Usage

powerpipe query alicloud_insights.query.ecs_snapshots_for_kms_key

SQL

select
s.arn as snapshot_arn
from
alicloud_ecs_snapshot as s
left join alicloud_kms_key k
on s.kms_key_id = k.key_id
where
k.arn = $1
and k.account_id = split_part($1,':',4)
and k.region = split_part($1,':',3)
and s.arn is not null;