UNPKG

@pulumi/gcp

Version:

A Pulumi package for creating and managing Google Cloud Platform resources.

278 lines (277 loc) • 11.9 kB
import * as pulumi from "@pulumi/pulumi"; /** * A Cloud Security Command Center (Cloud SCC) Big Query Export Config. * It represents exporting Security Command Center data, including assets, findings, and security marks * to a BigQuery instance. * * > **Note:** In order to use Cloud SCC resources, your organization must be enrolled * in [SCC Standard/Premium](https://cloud.google.com/security-command-center/docs/quickstart-security-command-center). * Without doing so, you may run into errors during resource creation. * * To get more information about FolderSccBigQueryExport, see: * * * [API documentation](https://cloud.google.com/security-command-center/docs/reference/rest/v1/folders.bigQueryExports) * * How-to Guides * * [Official Documentation](https://cloud.google.com/security-command-center/docs/how-to-analyze-findings-in-big-query) * * ## Example Usage * * ### Scc Folder Big Query Export Config Basic * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as gcp from "@pulumi/gcp"; * * const folder = new gcp.organizations.Folder("folder", { * parent: "organizations/123456789", * displayName: "folder-name", * deletionProtection: false, * }); * const _default = new gcp.bigquery.Dataset("default", { * datasetId: "my_dataset_id", * friendlyName: "test", * description: "This is a test description", * location: "US", * defaultTableExpirationMs: 3600000, * defaultPartitionExpirationMs: null, * labels: { * env: "default", * }, * }); * const customBigQueryExportConfig = new gcp.securitycenter.FolderSccBigQueryExport("custom_big_query_export_config", { * bigQueryExportId: "my-export", * folder: folder.folderId, * dataset: _default.id, * description: "Cloud Security Command Center Findings Big Query Export Config", * filter: "state=\"ACTIVE\" AND NOT mute=\"MUTED\"", * }); * ``` * * ## Import * * FolderSccBigQueryExport can be imported using any of these accepted formats: * * * `folders/{{folder}}/bigQueryExports/{{big_query_export_id}}` * * * `{{folder}}/{{big_query_export_id}}` * * When using the `pulumi import` command, FolderSccBigQueryExport can be imported using one of the formats above. For example: * * ```sh * $ pulumi import gcp:securitycenter/folderSccBigQueryExport:FolderSccBigQueryExport default folders/{{folder}}/bigQueryExports/{{big_query_export_id}} * ``` * * ```sh * $ pulumi import gcp:securitycenter/folderSccBigQueryExport:FolderSccBigQueryExport default {{folder}}/{{big_query_export_id}} * ``` */ export declare class FolderSccBigQueryExport extends pulumi.CustomResource { /** * Get an existing FolderSccBigQueryExport resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: FolderSccBigQueryExportState, opts?: pulumi.CustomResourceOptions): FolderSccBigQueryExport; /** * Returns true if the given object is an instance of FolderSccBigQueryExport. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is FolderSccBigQueryExport; /** * This must be unique within the organization. */ readonly bigQueryExportId: pulumi.Output<string>; /** * The time at which the BigQuery export was created. * A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. * Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". */ readonly createTime: pulumi.Output<string>; /** * The dataset to write findings' updates to. * Its format is "projects/[projectId]/datasets/[bigqueryDatasetId]". * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). */ readonly dataset: pulumi.Output<string>; /** * The description of the export (max of 1024 characters). */ readonly description: pulumi.Output<string>; /** * Expression that defines the filter to apply across create/update * events of findings. The * expression is a list of zero or more restrictions combined via * logical operators AND and OR. Parentheses are supported, and OR * has higher precedence than AND. * Restrictions have the form <field> <operator> <value> and may have * a - character in front of them to indicate negation. The fields * map to those defined in the corresponding resource. * The supported operators are: * * = for all value types. * * >, <, >=, <= for integer values. * * :, meaning substring matching, for strings. * The supported value types are: * * string literals in quotes. * * integer literals without quotes. * * boolean literals true and false without quotes. * See * [Filtering notifications](https://cloud.google.com/security-command-center/docs/how-to-api-filter-notifications) * for information on how to write a filter. */ readonly filter: pulumi.Output<string>; /** * The folder where Cloud Security Command Center Big Query Export * Config lives in. */ readonly folder: pulumi.Output<string>; /** * Email address of the user who last edited the BigQuery export. */ readonly mostRecentEditor: pulumi.Output<string>; /** * The resource name of this export, in the format * `projects/{{project}}/bigQueryExports/{{big_query_export_id}}`. * This field is provided in responses, and is ignored when provided in create requests. */ readonly name: pulumi.Output<string>; /** * The service account that needs permission to create table and upload data to the BigQuery dataset. */ readonly principal: pulumi.Output<string>; /** * The most recent time at which the BigQuery export was updated. * A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. * Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". */ readonly updateTime: pulumi.Output<string>; /** * Create a FolderSccBigQueryExport resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: FolderSccBigQueryExportArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering FolderSccBigQueryExport resources. */ export interface FolderSccBigQueryExportState { /** * This must be unique within the organization. */ bigQueryExportId?: pulumi.Input<string>; /** * The time at which the BigQuery export was created. * A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. * Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". */ createTime?: pulumi.Input<string>; /** * The dataset to write findings' updates to. * Its format is "projects/[projectId]/datasets/[bigqueryDatasetId]". * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). */ dataset?: pulumi.Input<string>; /** * The description of the export (max of 1024 characters). */ description?: pulumi.Input<string>; /** * Expression that defines the filter to apply across create/update * events of findings. The * expression is a list of zero or more restrictions combined via * logical operators AND and OR. Parentheses are supported, and OR * has higher precedence than AND. * Restrictions have the form <field> <operator> <value> and may have * a - character in front of them to indicate negation. The fields * map to those defined in the corresponding resource. * The supported operators are: * * = for all value types. * * >, <, >=, <= for integer values. * * :, meaning substring matching, for strings. * The supported value types are: * * string literals in quotes. * * integer literals without quotes. * * boolean literals true and false without quotes. * See * [Filtering notifications](https://cloud.google.com/security-command-center/docs/how-to-api-filter-notifications) * for information on how to write a filter. */ filter?: pulumi.Input<string>; /** * The folder where Cloud Security Command Center Big Query Export * Config lives in. */ folder?: pulumi.Input<string>; /** * Email address of the user who last edited the BigQuery export. */ mostRecentEditor?: pulumi.Input<string>; /** * The resource name of this export, in the format * `projects/{{project}}/bigQueryExports/{{big_query_export_id}}`. * This field is provided in responses, and is ignored when provided in create requests. */ name?: pulumi.Input<string>; /** * The service account that needs permission to create table and upload data to the BigQuery dataset. */ principal?: pulumi.Input<string>; /** * The most recent time at which the BigQuery export was updated. * A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. * Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". */ updateTime?: pulumi.Input<string>; } /** * The set of arguments for constructing a FolderSccBigQueryExport resource. */ export interface FolderSccBigQueryExportArgs { /** * This must be unique within the organization. */ bigQueryExportId: pulumi.Input<string>; /** * The dataset to write findings' updates to. * Its format is "projects/[projectId]/datasets/[bigqueryDatasetId]". * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). */ dataset: pulumi.Input<string>; /** * The description of the export (max of 1024 characters). */ description: pulumi.Input<string>; /** * Expression that defines the filter to apply across create/update * events of findings. The * expression is a list of zero or more restrictions combined via * logical operators AND and OR. Parentheses are supported, and OR * has higher precedence than AND. * Restrictions have the form <field> <operator> <value> and may have * a - character in front of them to indicate negation. The fields * map to those defined in the corresponding resource. * The supported operators are: * * = for all value types. * * >, <, >=, <= for integer values. * * :, meaning substring matching, for strings. * The supported value types are: * * string literals in quotes. * * integer literals without quotes. * * boolean literals true and false without quotes. * See * [Filtering notifications](https://cloud.google.com/security-command-center/docs/how-to-api-filter-notifications) * for information on how to write a filter. */ filter: pulumi.Input<string>; /** * The folder where Cloud Security Command Center Big Query Export * Config lives in. */ folder: pulumi.Input<string>; }