Policy types for @turbot/servicenow-gcp-storage

GCP > Storage > Bucket > ServiceNow

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/bucketServiceNow
Targets

GCP > Storage > Bucket > ServiceNow > Configuration Item

Synchronize the data for the GCP > Storage > Bucket based on the policies GCP > Storage > Bucket > ServiceNow > Configuration Item > *

The Configuration Item control is responsible for automatically synchronizing records in a designated ServiceNow table, maintaining an up-to-date reflection of the GCP > Storage > Bucket information within the ServiceNow CMDB.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/bucketServiceNowConfigurationItem
Valid Value
[
"Skip",
"Check: Archived",
"Check: Deleted",
"Check: Sync",
"Enforce: Archived",
"Enforce: Deleted",
"Enforce: Sync",
"Enforce: Sync, archive on delete"
]
Schema
{
"type": "string",
"enum": [
"Skip",
"Check: Archived",
"Check: Deleted",
"Check: Sync",
"Enforce: Archived",
"Enforce: Deleted",
"Enforce: Sync",
"Enforce: Sync, archive on delete"
],
"example": [
"Skip"
],
"default": "Skip"
}

GCP > Storage > Bucket > ServiceNow > Configuration Item > Record

The policy facilitates the accurate representation of cloud resource within the ServiceNow environment, ensuring that critical data is effectively mapped and managed. Attribute of an GCP > Storage > Bucket is systematically mapped to a specific column in a ServiceNow table.

The policy allows enabling organizations to select and map only those attributes that are most relevant to their operational needs. It significantly reduces the manual effort involved in data transfer and minimizes the risk of errors, thereby enhancing the overall efficiency of data management.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/bucketServiceNowConfigurationItemRecord
Default Template Input
"{\n resource: bucket{\n data\n metadata\n turbot {\n akas\n id\n tags\n title\n }\n }\n}\n"
Default Template
"acl: {{ $.resource.data.acl | dump | safe }}\nbilling_requester_pays: {{ $.resource.data.billing.requesterPays | dump | safe }}\nbucket_location: {{ $.resource.data.location | dump | safe }}\nbucket_name: {{ $.resource.data.name | dump | safe }}\ndefault_kms_key_name: {{ $.resource.data.encryption.defaultKmsKeyName | dump | safe }}\ndefault_object_acl: {{ $.resource.data.defaultObjectAcl | dump | safe }}\niam_configuration_bucket_policy_only_enabled: {{ $.resource.data.iamConfiguration.bucketPolicyOnly.enabled | dump | safe }}\niam_configuration_public_access_prevention: {{ $.resource.data.iamConfiguration.publicAccessPrevention | dump | safe }}\niam_configuration_uniform_bucket_level_access_enabled: {{ $.resource.data.iamConfiguration.uniformBucketLevelAccess.enabled | dump | safe }}\niam_policy: {{ $.resource.data.iamPolicy | dump | safe }}\nid: {{ $.resource.data.id | dump | safe }}\nlabels: {{ $.resource.data.labels | dump | safe }}\nlifecycle_rules: {{ $.resource.data.lifecycle.rule | dump | safe }}\nlocation_type: {{ $.resource.data.locationType | dump | safe }}\nlog_bucket: {{ $.resource.data.logging.logBucket | dump | safe }}\nlog_object_prefix: {{ $.resource.data.logging.logObjectPrefix | dump | safe }}\nmetageneration: {{ $.resource.data.metageneration | dump | safe }}\nproject: {{ $.resource.metadata.gcp.projectId | dump | safe }}\nproject_number: {{ $.resource.data.projectNumber | dump | safe }}\nregion: {{ $.resource.metadata.gcp.regionName | dump | safe }}\nretention_policy: {{ $.resource.data.retentionPolicy | dump | safe }}\nself_link: {{ $.resource.data.selfLink | dump | safe }}\nstorage_class: {{ $.resource.data.storageClass | dump | safe }}\ntags: {{ $.resource.turbot.tags | dump | safe }}\ntime_created: {{ $.resource.data.timeCreated | dump | safe }}\nupdated: {{ $.resource.data.updated | dump | safe }}\nversioning_enabled: {{ $.resource.data.versioning.enabled | dump | safe }}\nwebsite_main_page_suffix: {{ $.resource.data.website.mainPageSuffix | dump | safe }}\nwebsite_not_found_page: {{ $.resource.data.website.notFoundPage | dump | safe }}\n"
Schema
{
"type": "object"
}

GCP > Storage > Bucket > ServiceNow > Configuration Item > Table Definition

This policy specifically allows users to define two key aspects: the name of the ServiceNow table where the GCP > Storage > Bucket data will be stored, and the details of the columns used for archiving purposes.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/bucketServiceNowConfigurationItemTableDefinition
Default Template Input
[
"{\n serviceNowInstance: resources(filter: \"resourceTypeId:tmod:@turbot/servicenow#/resource/types/instance level:self limit:1\") {\n items {\n turbot {\n id\n }\n }\n }\n}\n",
"{\n tableDefinition: policyValues(filter: \"policyTypeId:tmod:@turbot/servicenow-gcp-storage#/policy/types/bucketServiceNowTableDefinition resourceId:{{$.serviceNowInstance.items[0].turbot.id}} level:self\") {\n items {\n value\n }\n }\n applicationScope: policyValues(filter: \"policyTypeId:tmod:@turbot/servicenow#/policy/types/serviceNowApplicationScope resourceId:{{$.serviceNowInstance.items[0].turbot.id}} level:self\") {\n items {\n value\n }\n }\n}\n"
]
Default Template
"tableName: "{%- if $.applicationScope.items | length == 0 or $.tableDefinition.items | length == 0 %} {%- else %}{{$.applicationScope.items[0].value}}_{{$.tableDefinition.items[0].value.table.name | lower}}{% endif %}"\n"
Schema
{
"type": "object",
"additionalProperties": false,
"required": [
"tableName"
],
"properties": {
"tableName": {
"type": "string"
},
"archiveColumns": {
"type": "object"
}
}
}

GCP > Storage > Bucket > ServiceNow > Table

Configure a Table for GCP > Storage > Bucket resource type in ServiceNow via the GCP > Storage > Bucket > ServiceNow > Table > * policies.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/bucketServiceNowTable
Valid Value
[
"Skip",
"Check: Configured",
"Enforce: Configured"
]
Schema
{
"type": "string",
"enum": [
"Skip",
"Check: Configured",
"Enforce: Configured"
],
"example": [
"Skip"
],
"default": "Skip"
}

GCP > Storage > Bucket > ServiceNow > Table > Definition

The policy enables the definition of ServiceNow table properties, including its name and the base table from which it extends, and details the specific columns required for representing GCP > Storage > Bucket data.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/bucketServiceNowTableDefinition
Schema
{
"type": "object",
"additionalProperties": false,
"required": [
"table",
"columns"
],
"properties": {
"table": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string",
"pattern": "^([0-9a-z_])+$"
},
"label": {
"type": "string"
},
"extendsTable": {
"type": "string",
"pattern": "^([0-9a-z_])+$"
}
}
},
"columns": {
"type": "array",
"description": "An array of columns with their mappings to the CMDB.",
"default": [],
"items": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string",
"description": "The name of the column in the table.",
"pattern": "^([0-9a-z_])+$"
},
"label": {
"type": "string",
"description": "The label for the column."
},
"type": {
"description": "The data type of the column.",
"type": "string"
},
"size": {
"type": "integer",
"description": "The length for data type."
}
}
}
}
},
"default": {
"table": {
"name": "guardrails_gcp_storage_bucket",
"label": "GCP > Storage > Bucket",
"extendsTable": "cmdb_ci"
},
"columns": [
{
"name": "acl",
"label": "ACL",
"type": "string",
"size": 1000
},
{
"name": "billing_requester_pays",
"label": "Billing Requester Pays",
"type": "boolean"
},
{
"name": "bucket_location",
"label": "Bucket Location"
},
{
"name": "bucket_name",
"label": "Bucket Name"
},
{
"name": "default_kms_key_name",
"label": "Default Kms Key Name"
},
{
"name": "default_object_acl",
"label": "Default Object ACL",
"type": "string",
"size": 1000
},
{
"name": "iam_configuration_bucket_policy_only_enabled",
"label": "IAM Configuration Bucket Policy Only Enabled",
"type": "boolean"
},
{
"name": "iam_configuration_public_access_prevention",
"label": "IAM Configuration Public Access Prevention"
},
{
"name": "iam_configuration_uniform_bucket_level_access_enabled",
"label": "IAM Configuration Uniform Bucket Level Access Enabled",
"type": "boolean"
},
{
"name": "iam_policy",
"label": "IAM Policy",
"type": "string",
"size": 1000
},
{
"name": "id",
"label": "ID"
},
{
"name": "labels",
"label": "Labels",
"type": "string",
"size": 1000
},
{
"name": "lifecycle_rules",
"label": "Lifecycle Rules",
"type": "string",
"size": 1000
},
{
"name": "location_type",
"label": "Location Type"
},
{
"name": "log_bucket",
"label": "Log Bucket"
},
{
"name": "log_object_prefix",
"label": "Log Object Prefix"
},
{
"name": "metageneration",
"label": "Metageneration"
},
{
"name": "project",
"label": "Project",
"type": "string"
},
{
"name": "project_number",
"label": "Project Number"
},
{
"name": "region",
"label": "Region"
},
{
"name": "retention_policy",
"label": "Retention Policy",
"type": "string",
"size": 1000
},
{
"name": "self_link",
"label": "Self Link"
},
{
"name": "storage_class",
"label": "Storage Class"
},
{
"name": "tags",
"label": "Tags",
"type": "string",
"size": 1000
},
{
"name": "time_created",
"label": "Time Created"
},
{
"name": "updated",
"label": "Updated"
},
{
"name": "versioning_enabled",
"label": "Versioning Enabled",
"type": "boolean"
},
{
"name": "website_main_page_suffix",
"label": "Website Main Page Suffix"
},
{
"name": "website_not_found_page",
"label": "Website Not Found Page"
}
]
}
}

GCP > Storage > Object > ServiceNow

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/objectServiceNow
Targets

GCP > Storage > Object > ServiceNow > Configuration Item

Synchronize the data for the GCP > Storage > Object based on the policies GCP > Storage > Object > ServiceNow > Configuration Item > *

The Configuration Item control is responsible for automatically synchronizing records in a designated ServiceNow table, maintaining an up-to-date reflection of the GCP > Storage > Object information within the ServiceNow CMDB.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/objectServiceNowConfigurationItem
Valid Value
[
"Skip",
"Check: Archived",
"Check: Deleted",
"Check: Sync",
"Enforce: Archived",
"Enforce: Deleted",
"Enforce: Sync",
"Enforce: Sync, archive on delete"
]
Schema
{
"type": "string",
"enum": [
"Skip",
"Check: Archived",
"Check: Deleted",
"Check: Sync",
"Enforce: Archived",
"Enforce: Deleted",
"Enforce: Sync",
"Enforce: Sync, archive on delete"
],
"example": [
"Skip"
],
"default": "Skip"
}

GCP > Storage > Object > ServiceNow > Configuration Item > Record

The policy facilitates the accurate representation of cloud resource within the ServiceNow environment, ensuring that critical data is effectively mapped and managed. Attribute of an GCP > Storage > Object is systematically mapped to a specific column in a ServiceNow table.

The policy allows enabling organizations to select and map only those attributes that are most relevant to their operational needs. It significantly reduces the manual effort involved in data transfer and minimizes the risk of errors, thereby enhancing the overall efficiency of data management.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/objectServiceNowConfigurationItemRecord
Default Template Input
"{\n resource: object{\n data\n metadata\n turbot {\n akas\n id\n tags\n title\n }\n }\n}\n"
Default Template
"acl: {{ $.resource.data.acl | dump | safe }}\nbucket: {{ $.resource.data.bucket | dump | safe }}\ncache_control: {{ $.resource.data.cacheControl | dump | safe }}\ncomponent_count: {{ $.resource.data.componentCount | dump | safe }}\ncontent_disposition: {{ $.resource.data.contentDisposition | dump | safe }}\ncontent_encoding: {{ $.resource.data.contentEncoding | dump | safe }}\ncontent_language: {{ $.resource.data.contentLanguage | dump | safe }}\ncontent_type: {{ $.resource.data.contentType | dump | safe }}\ncrc32c: {{ $.resource.data.crc32C | dump | safe }}\ncustom_time: {{ $.resource.data.customTime | dump | safe }}\ncustomer_encryption: {{ $.resource.data.customerEncryption | dump | safe }}\nevent_based_hold: {{ $.resource.data.eventBasedHold | dump | safe }}\ngeneration: {{ $.resource.data.generation | dump | safe }}\niam_policy: {{ $.resource.data.iamPolicy | dump | safe }}\nid: {{ $.resource.data.id | dump | safe }}\nkind: {{ $.resource.data.kind | dump | safe }}\nkms_key_name: {{ $.resource.data.kmsKeyName | dump | safe }}\nmd5_hash: {{ $.resource.data.md5Hash | dump | safe }}\nmedia_link: {{ $.resource.data.mediaLink | dump | safe }}\nobject_name: {{ $.resource.data.name | dump | safe }}\nowner: {{ $.resource.data.owner | dump | safe }}\nproject: {{ $.resource.data.project | dump | safe }}\nretention_expiration_time: {{ $.resource.data.retentionExpirationTime | dump | safe }}\nself_link: {{ $.resource.data.selfLink | dump | safe }}\nsize: {{ $.resource.data.size | dump | safe }}\nstorage_class: {{ $.resource.data.storageClass | dump | safe }}\ntemporary_hold: {{ $.resource.data.temporaryHold | dump | safe }}\ntime_created: {{ $.resource.data.timeCreated | dump | safe }}\ntime_deleted: {{ $.resource.data.timeDeleted | dump | safe }}\ntime_storage_class_updated: {{ $.resource.data.timeStorageClassUpdated | dump | safe }}\ntitle: {{ $.resource.data.title | dump | safe }}\nupdated: {{ $.resource.data.updated | dump | safe }}\n"
Schema
{
"type": "object"
}

GCP > Storage > Object > ServiceNow > Configuration Item > Table Definition

This policy specifically allows users to define two key aspects: the name of the ServiceNow table where the GCP > Storage > Object data will be stored, and the details of the columns used for archiving purposes.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/objectServiceNowConfigurationItemTableDefinition
Default Template Input
[
"{\n serviceNowInstance: resources(filter: \"resourceTypeId:tmod:@turbot/servicenow#/resource/types/instance level:self limit:1\") {\n items {\n turbot {\n id\n }\n }\n }\n}\n",
"{\n tableDefinition: policyValues(filter: \"policyTypeId:tmod:@turbot/servicenow-gcp-storage#/policy/types/objectServiceNowTableDefinition resourceId:{{$.serviceNowInstance.items[0].turbot.id}} level:self\") {\n items {\n value\n }\n }\n applicationScope: policyValues(filter: \"policyTypeId:tmod:@turbot/servicenow#/policy/types/serviceNowApplicationScope resourceId:{{$.serviceNowInstance.items[0].turbot.id}} level:self\") {\n items {\n value\n }\n }\n}\n"
]
Default Template
"tableName: "{%- if $.applicationScope.items | length == 0 or $.tableDefinition.items | length == 0 %} {%- else %}{{$.applicationScope.items[0].value}}_{{$.tableDefinition.items[0].value.table.name | lower}}{% endif %}"\n"
Schema
{
"type": "object",
"additionalProperties": false,
"required": [
"tableName"
],
"properties": {
"tableName": {
"type": "string"
},
"archiveColumns": {
"type": "object"
}
}
}

GCP > Storage > Object > ServiceNow > Table

Configure a Table for GCP > Storage > Object resource type in ServiceNow via the GCP > Storage > Object > ServiceNow > Table > * policies.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/objectServiceNowTable
Valid Value
[
"Skip",
"Check: Configured",
"Enforce: Configured"
]
Schema
{
"type": "string",
"enum": [
"Skip",
"Check: Configured",
"Enforce: Configured"
],
"example": [
"Skip"
],
"default": "Skip"
}

GCP > Storage > Object > ServiceNow > Table > Definition

The policy enables the definition of ServiceNow table properties, including its name and the base table from which it extends, and details the specific columns required for representing GCP > Storage > Object data.

URI
tmod:@turbot/servicenow-gcp-storage#/policy/types/objectServiceNowTableDefinition
Schema
{
"type": "object",
"additionalProperties": false,
"required": [
"table",
"columns"
],
"properties": {
"table": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string",
"pattern": "^([0-9a-z_])+$"
},
"label": {
"type": "string"
},
"extendsTable": {
"type": "string",
"pattern": "^([0-9a-z_])+$"
}
}
},
"columns": {
"type": "array",
"description": "An array of columns with their mappings to the CMDB.",
"default": [],
"items": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string",
"description": "The name of the column in the table.",
"pattern": "^([0-9a-z_])+$"
},
"label": {
"type": "string",
"description": "The label for the column."
},
"type": {
"description": "The data type of the column.",
"type": "string"
},
"size": {
"type": "integer",
"description": "The length for data type."
}
}
}
}
},
"default": {
"table": {
"name": "guardrails_gcp_storage_object",
"label": "GCP > Storage > Object",
"extendsTable": "cmdb_ci"
},
"columns": [
{
"name": "acl",
"label": "ACL",
"type": "string",
"size": 1000
},
{
"name": "bucket",
"label": "Bucket"
},
{
"name": "cache_control",
"label": "Cache Control"
},
{
"name": "component_count",
"label": "Component Count"
},
{
"name": "content_disposition",
"label": "Content Disposition"
},
{
"name": "content_encoding",
"label": "Content Encoding"
},
{
"name": "content_language",
"label": "Content Language"
},
{
"name": "content_type",
"label": "Content Type"
},
{
"name": "crc32c",
"label": "CRC32C"
},
{
"name": "custom_time",
"label": "Custom Time"
},
{
"name": "customer_encryption",
"label": "Customer Encryption",
"type": "string",
"size": 1000
},
{
"name": "event_based_hold",
"label": "Event Based Hold",
"type": "boolean"
},
{
"name": "generation",
"label": "Generation"
},
{
"name": "iam_policy",
"label": "IAM Policy",
"type": "string",
"size": 1000
},
{
"name": "id",
"label": "ID"
},
{
"name": "kind",
"label": "Kind"
},
{
"name": "kms_key_name",
"label": "KMS Key Name"
},
{
"name": "md5_hash",
"label": "MD5 Hash"
},
{
"name": "media_link",
"label": "Media Link"
},
{
"name": "object_name",
"label": "Name"
},
{
"name": "owner",
"label": "Owner",
"type": "string",
"size": 1000
},
{
"name": "project",
"label": "Project"
},
{
"name": "retention_expiration_time",
"label": "Retention Expiration Time"
},
{
"name": "self_link",
"label": "Self Link"
},
{
"name": "size",
"label": "Size"
},
{
"name": "storage_class",
"label": "Storage Class"
},
{
"name": "temporary_hold",
"label": "Temporary Hold",
"type": "boolean"
},
{
"name": "time_created",
"label": "Time Created"
},
{
"name": "time_deleted",
"label": "Time Deleted"
},
{
"name": "time_storage_class_updated",
"label": "Time Storage Class Updated"
},
{
"name": "title",
"label": "Title"
},
{
"name": "updated",
"label": "Updated"
}
]
}
}