turbot/aws_compliance

Query: ec2_ami_not_older_than_90_days

Usage

powerpipe query aws_compliance.query.ec2_ami_not_older_than_90_days

Steampipe Tables

SQL

select
image_id as resource,
case
when creation_date >= (current_date - interval '90 days') then 'ok'
else 'alarm'
end as status,
title || ' created ' || to_char(creation_date , 'DD-Mon-YYYY') || ' (' || extract(day from current_timestamp - creation_date) || ' days).' as reason
, region, account_id
from
aws_ec2_ami;

Controls

The query is being used by the following controls: