turbot/gcp_compliance

Query: sql_instance_with_labels

Usage

powerpipe query gcp_compliance.query.sql_instance_with_labels

SQL

select
self_link resource,
case
when labels is not null then 'ok'
else 'alarm'
end as status,
case
when labels is not null then title || ' has labels attached.'
else title || ' no labels attached.'
end as reason
, location as location, project as project
from
gcp_sql_database_instance;

Controls

The query is being used by the following controls: