turbot/alicloud_compliance

Query: rds_instance_postgresql_log_disconnections_parameter_on

Usage

powerpipe query alicloud_compliance.query.rds_instance_postgresql_log_disconnections_parameter_on

Steampipe Tables

SQL

select
arn as resource,
case
when engine != 'PostgreSQL' then 'skip'
when parameters -> 'RunningParameters' -> 'DBInstanceParameter' @> '[{"ParameterName": "log_disconnections", "ParameterValue": "on"}]' then 'ok'
else 'alarm'
end as status,
case
when engine != 'PostgreSQL' then title || ' is ' || engine || ' server.'
when parameters -> 'RunningParameters' -> 'DBInstanceParameter' @> '[{"ParameterName": "log_disconnections", "ParameterValue": "on"}]' then title || ' ''log_disconnections'' parameter set to ''on''.'
else title || ' ''log_disconnections'' parameter set to ''off''.'
end as reason
, account_id as account_id, region as region
from
alicloud_rds_instance;

Controls

The query is being used by the following controls: