turbot/terraform_aws_compliance

Query: vpc_eip_associated

Usage

powerpipe query terraform_aws_compliance.query.vpc_eip_associated

Steampipe Tables

SQL

select
address as resource,
case
when (attributes_std -> 'vpc') is null then 'skip'
when (attributes_std -> 'instance') is not null or (attributes_std -> 'network_interface') is not null then 'ok'
else 'alarm'
end status,
split_part(address, '.', 2) || case
when (attributes_std -> 'vpc') is null then ' not associated with VPC'
when (attributes_std -> 'instance') is not null or (attributes_std -> 'network_interface') is not null then ' associated with an instance or network interface'
else ' not associated with an instance or network interface'
end || '.' as reason
, path || ':' || start_line
from
terraform_resource
where
type = 'aws_eip';

Controls

The query is being used by the following controls: