Table: turbot_policy_type
List all the policy types known to Turbot.
Examples
List all policy types
select id, uri, trunk_titlefrom turbot_policy_typeorder by trunk_title;
List all policy types with additional detail
select trunk_title as "policy_name", description, schema ->> 'enum' as "policy_settings", uri as "policy_uri"from turbot_policy_typeorder by trunk_title;
List all policy types for AWS S3
select id, uri, trunk_titlefrom turbot_policy_typewhere mod_uri like 'tmod:@turbot/aws-s3%'order by trunk_title;
Count policy types by cloud provider
select sum( case when mod_uri like 'tmod:@turbot/aws-%' then 1 else 0 end ) as aws, sum( case when mod_uri like 'tmod:@turbot/azure-%' then 1 else 0 end ) as azure, sum( case when mod_uri like 'tmod:@turbot/gcp-%' then 1 else 0 end ) as gcp, count(*) as totalfrom turbot_policy_type;
Policy types that target AWS > S3 > Bucket
select trunk_title, uri, targetsfrom turbot_policy_typewhere targets ? 'tmod:@turbot/aws-s3#/resource/types/bucket';
Schema for turbot_policy_type
Name | Type | Operators | Description |
---|---|---|---|
_ctx | jsonb | Steampipe context in JSON form, e.g. connection_name. | |
akas | jsonb | AKA (also known as) identifiers for the policy type. | |
category_id | bigint | ID of the control category for the policy type. | |
category_uri | text | URI of the control category for the policy type. | |
create_timestamp | timestamp with time zone | When the policy type was first discovered by Turbot. (It may have been created earlier.) | |
default_template | text | Default template used to calculate template-based policy values. Should be a Jinja based YAML string. | |
description | text | Description of the policy type. | |
icon | text | Icon of the policy type. | |
id | bigint | = | Unique identifier of the policy type. |
mod_uri | text | URI of the mod that contains the policy type. | |
parent_id | text | ID for the parent of this policy type. | |
path | jsonb | Hierarchy path with all identifiers of ancestors of the policy type. | |
read_only | boolean | If true user-defined policy settings are blocked from being created. | |
schema | jsonb | JSON schema defining the allowed schema for policy values for any targeted resources. | |
secret | boolean | JSON schema defining valid values for the policy type. | |
secret_level | text | Secret Level: SECRET, CONFIDENTIAL or NONE. | |
targets | jsonb | URIs of the resource types targeted by this policy type. | |
title | text | Title of the policy type. | |
trunk_title | text | Title with full path of the policy type. | |
update_timestamp | timestamp with time zone | When the policy type was last updated in Turbot. | |
uri | text | = | URI of the policy type. |
version_id | bigint | Unique identifier for this version of the policy type. | |
workspace | text | Specifies the workspace URL. |