gcp.logging.OrganizationSink
Explore with Pulumi AI
Manages a organization-level logging sink. For more information see:
- API documentation
- How-to Guides
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const log_bucket = new gcp.storage.Bucket("log-bucket", {
name: "organization-logging-bucket",
location: "US",
});
const my_sink = new gcp.logging.OrganizationSink("my-sink", {
name: "my-sink",
description: "some explanation on what this is",
orgId: "123456789",
destination: pulumi.interpolate`storage.googleapis.com/${log_bucket.name}`,
filter: "resource.type = gce_instance AND severity >= WARNING",
});
const log_writer = new gcp.projects.IAMMember("log-writer", {
project: "your-project-id",
role: "roles/storage.objectCreator",
member: my_sink.writerIdentity,
});
import pulumi
import pulumi_gcp as gcp
log_bucket = gcp.storage.Bucket("log-bucket",
name="organization-logging-bucket",
location="US")
my_sink = gcp.logging.OrganizationSink("my-sink",
name="my-sink",
description="some explanation on what this is",
org_id="123456789",
destination=log_bucket.name.apply(lambda name: f"storage.googleapis.com/{name}"),
filter="resource.type = gce_instance AND severity >= WARNING")
log_writer = gcp.projects.IAMMember("log-writer",
project="your-project-id",
role="roles/storage.objectCreator",
member=my_sink.writer_identity)
package main
import (
"fmt"
"github.com/pulumi/pulumi-gcp/sdk/v8/go/gcp/logging"
"github.com/pulumi/pulumi-gcp/sdk/v8/go/gcp/projects"
"github.com/pulumi/pulumi-gcp/sdk/v8/go/gcp/storage"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := storage.NewBucket(ctx, "log-bucket", &storage.BucketArgs{
Name: pulumi.String("organization-logging-bucket"),
Location: pulumi.String("US"),
})
if err != nil {
return err
}
_, err = logging.NewOrganizationSink(ctx, "my-sink", &logging.OrganizationSinkArgs{
Name: pulumi.String("my-sink"),
Description: pulumi.String("some explanation on what this is"),
OrgId: pulumi.String("123456789"),
Destination: log_bucket.Name.ApplyT(func(name string) (string, error) {
return fmt.Sprintf("storage.googleapis.com/%v", name), nil
}).(pulumi.StringOutput),
Filter: pulumi.String("resource.type = gce_instance AND severity >= WARNING"),
})
if err != nil {
return err
}
_, err = projects.NewIAMMember(ctx, "log-writer", &projects.IAMMemberArgs{
Project: pulumi.String("your-project-id"),
Role: pulumi.String("roles/storage.objectCreator"),
Member: my_sink.WriterIdentity,
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var log_bucket = new Gcp.Storage.Bucket("log-bucket", new()
{
Name = "organization-logging-bucket",
Location = "US",
});
var my_sink = new Gcp.Logging.OrganizationSink("my-sink", new()
{
Name = "my-sink",
Description = "some explanation on what this is",
OrgId = "123456789",
Destination = log_bucket.Name.Apply(name => $"storage.googleapis.com/{name}"),
Filter = "resource.type = gce_instance AND severity >= WARNING",
});
var log_writer = new Gcp.Projects.IAMMember("log-writer", new()
{
Project = "your-project-id",
Role = "roles/storage.objectCreator",
Member = my_sink.WriterIdentity,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.storage.Bucket;
import com.pulumi.gcp.storage.BucketArgs;
import com.pulumi.gcp.logging.OrganizationSink;
import com.pulumi.gcp.logging.OrganizationSinkArgs;
import com.pulumi.gcp.projects.IAMMember;
import com.pulumi.gcp.projects.IAMMemberArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var log_bucket = new Bucket("log-bucket", BucketArgs.builder()
.name("organization-logging-bucket")
.location("US")
.build());
var my_sink = new OrganizationSink("my-sink", OrganizationSinkArgs.builder()
.name("my-sink")
.description("some explanation on what this is")
.orgId("123456789")
.destination(log_bucket.name().applyValue(name -> String.format("storage.googleapis.com/%s", name)))
.filter("resource.type = gce_instance AND severity >= WARNING")
.build());
var log_writer = new IAMMember("log-writer", IAMMemberArgs.builder()
.project("your-project-id")
.role("roles/storage.objectCreator")
.member(my_sink.writerIdentity())
.build());
}
}
resources:
my-sink:
type: gcp:logging:OrganizationSink
properties:
name: my-sink
description: some explanation on what this is
orgId: '123456789'
destination: storage.googleapis.com/${["log-bucket"].name}
filter: resource.type = gce_instance AND severity >= WARNING
log-bucket:
type: gcp:storage:Bucket
properties:
name: organization-logging-bucket
location: US
log-writer:
type: gcp:projects:IAMMember
properties:
project: your-project-id
role: roles/storage.objectCreator
member: ${["my-sink"].writerIdentity}
Create OrganizationSink Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new OrganizationSink(name: string, args: OrganizationSinkArgs, opts?: CustomResourceOptions);
@overload
def OrganizationSink(resource_name: str,
args: OrganizationSinkArgs,
opts: Optional[ResourceOptions] = None)
@overload
def OrganizationSink(resource_name: str,
opts: Optional[ResourceOptions] = None,
destination: Optional[str] = None,
org_id: Optional[str] = None,
bigquery_options: Optional[OrganizationSinkBigqueryOptionsArgs] = None,
description: Optional[str] = None,
disabled: Optional[bool] = None,
exclusions: Optional[Sequence[OrganizationSinkExclusionArgs]] = None,
filter: Optional[str] = None,
include_children: Optional[bool] = None,
intercept_children: Optional[bool] = None,
name: Optional[str] = None)
func NewOrganizationSink(ctx *Context, name string, args OrganizationSinkArgs, opts ...ResourceOption) (*OrganizationSink, error)
public OrganizationSink(string name, OrganizationSinkArgs args, CustomResourceOptions? opts = null)
public OrganizationSink(String name, OrganizationSinkArgs args)
public OrganizationSink(String name, OrganizationSinkArgs args, CustomResourceOptions options)
type: gcp:logging:OrganizationSink
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args OrganizationSinkArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args OrganizationSinkArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args OrganizationSinkArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args OrganizationSinkArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args OrganizationSinkArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var organizationSinkResource = new Gcp.Logging.OrganizationSink("organizationSinkResource", new()
{
Destination = "string",
OrgId = "string",
BigqueryOptions = new Gcp.Logging.Inputs.OrganizationSinkBigqueryOptionsArgs
{
UsePartitionedTables = false,
},
Description = "string",
Disabled = false,
Exclusions = new[]
{
new Gcp.Logging.Inputs.OrganizationSinkExclusionArgs
{
Filter = "string",
Name = "string",
Description = "string",
Disabled = false,
},
},
Filter = "string",
IncludeChildren = false,
InterceptChildren = false,
Name = "string",
});
example, err := logging.NewOrganizationSink(ctx, "organizationSinkResource", &logging.OrganizationSinkArgs{
Destination: pulumi.String("string"),
OrgId: pulumi.String("string"),
BigqueryOptions: &logging.OrganizationSinkBigqueryOptionsArgs{
UsePartitionedTables: pulumi.Bool(false),
},
Description: pulumi.String("string"),
Disabled: pulumi.Bool(false),
Exclusions: logging.OrganizationSinkExclusionArray{
&logging.OrganizationSinkExclusionArgs{
Filter: pulumi.String("string"),
Name: pulumi.String("string"),
Description: pulumi.String("string"),
Disabled: pulumi.Bool(false),
},
},
Filter: pulumi.String("string"),
IncludeChildren: pulumi.Bool(false),
InterceptChildren: pulumi.Bool(false),
Name: pulumi.String("string"),
})
var organizationSinkResource = new OrganizationSink("organizationSinkResource", OrganizationSinkArgs.builder()
.destination("string")
.orgId("string")
.bigqueryOptions(OrganizationSinkBigqueryOptionsArgs.builder()
.usePartitionedTables(false)
.build())
.description("string")
.disabled(false)
.exclusions(OrganizationSinkExclusionArgs.builder()
.filter("string")
.name("string")
.description("string")
.disabled(false)
.build())
.filter("string")
.includeChildren(false)
.interceptChildren(false)
.name("string")
.build());
organization_sink_resource = gcp.logging.OrganizationSink("organizationSinkResource",
destination="string",
org_id="string",
bigquery_options={
"use_partitioned_tables": False,
},
description="string",
disabled=False,
exclusions=[{
"filter": "string",
"name": "string",
"description": "string",
"disabled": False,
}],
filter="string",
include_children=False,
intercept_children=False,
name="string")
const organizationSinkResource = new gcp.logging.OrganizationSink("organizationSinkResource", {
destination: "string",
orgId: "string",
bigqueryOptions: {
usePartitionedTables: false,
},
description: "string",
disabled: false,
exclusions: [{
filter: "string",
name: "string",
description: "string",
disabled: false,
}],
filter: "string",
includeChildren: false,
interceptChildren: false,
name: "string",
});
type: gcp:logging:OrganizationSink
properties:
bigqueryOptions:
usePartitionedTables: false
description: string
destination: string
disabled: false
exclusions:
- description: string
disabled: false
filter: string
name: string
filter: string
includeChildren: false
interceptChildren: false
name: string
orgId: string
OrganizationSink Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The OrganizationSink resource accepts the following input properties:
- Destination string
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- Org
Id string - The numeric ID of the organization to be exported to the sink.
- Bigquery
Options OrganizationSink Bigquery Options - Options that affect sinks exporting data to BigQuery. Structure documented below.
- Description string
- A description of this sink. The maximum length of the description is 8000 characters.
- Disabled bool
- If set to True, then this sink is disabled and it does not export any log entries.
- Exclusions
List<Organization
Sink Exclusion> - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - Filter string
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- Include
Children bool - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- Intercept
Children bool - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- Name string
- The name of the logging sink.
- Destination string
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- Org
Id string - The numeric ID of the organization to be exported to the sink.
- Bigquery
Options OrganizationSink Bigquery Options Args - Options that affect sinks exporting data to BigQuery. Structure documented below.
- Description string
- A description of this sink. The maximum length of the description is 8000 characters.
- Disabled bool
- If set to True, then this sink is disabled and it does not export any log entries.
- Exclusions
[]Organization
Sink Exclusion Args - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - Filter string
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- Include
Children bool - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- Intercept
Children bool - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- Name string
- The name of the logging sink.
- destination String
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- org
Id String - The numeric ID of the organization to be exported to the sink.
- bigquery
Options OrganizationSink Bigquery Options - Options that affect sinks exporting data to BigQuery. Structure documented below.
- description String
- A description of this sink. The maximum length of the description is 8000 characters.
- disabled Boolean
- If set to True, then this sink is disabled and it does not export any log entries.
- exclusions
List<Organization
Sink Exclusion> - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - filter String
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- include
Children Boolean - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- intercept
Children Boolean - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- name String
- The name of the logging sink.
- destination string
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- org
Id string - The numeric ID of the organization to be exported to the sink.
- bigquery
Options OrganizationSink Bigquery Options - Options that affect sinks exporting data to BigQuery. Structure documented below.
- description string
- A description of this sink. The maximum length of the description is 8000 characters.
- disabled boolean
- If set to True, then this sink is disabled and it does not export any log entries.
- exclusions
Organization
Sink Exclusion[] - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - filter string
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- include
Children boolean - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- intercept
Children boolean - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- name string
- The name of the logging sink.
- destination str
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- org_
id str - The numeric ID of the organization to be exported to the sink.
- bigquery_
options OrganizationSink Bigquery Options Args - Options that affect sinks exporting data to BigQuery. Structure documented below.
- description str
- A description of this sink. The maximum length of the description is 8000 characters.
- disabled bool
- If set to True, then this sink is disabled and it does not export any log entries.
- exclusions
Sequence[Organization
Sink Exclusion Args] - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - filter str
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- include_
children bool - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- intercept_
children bool - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- name str
- The name of the logging sink.
- destination String
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- org
Id String - The numeric ID of the organization to be exported to the sink.
- bigquery
Options Property Map - Options that affect sinks exporting data to BigQuery. Structure documented below.
- description String
- A description of this sink. The maximum length of the description is 8000 characters.
- disabled Boolean
- If set to True, then this sink is disabled and it does not export any log entries.
- exclusions List<Property Map>
- Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - filter String
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- include
Children Boolean - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- intercept
Children Boolean - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- name String
- The name of the logging sink.
Outputs
All input properties are implicitly available as output properties. Additionally, the OrganizationSink resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Writer
Identity string - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- Id string
- The provider-assigned unique ID for this managed resource.
- Writer
Identity string - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- id String
- The provider-assigned unique ID for this managed resource.
- writer
Identity String - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- id string
- The provider-assigned unique ID for this managed resource.
- writer
Identity string - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- id str
- The provider-assigned unique ID for this managed resource.
- writer_
identity str - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- id String
- The provider-assigned unique ID for this managed resource.
- writer
Identity String - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
Look up Existing OrganizationSink Resource
Get an existing OrganizationSink resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: OrganizationSinkState, opts?: CustomResourceOptions): OrganizationSink
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
bigquery_options: Optional[OrganizationSinkBigqueryOptionsArgs] = None,
description: Optional[str] = None,
destination: Optional[str] = None,
disabled: Optional[bool] = None,
exclusions: Optional[Sequence[OrganizationSinkExclusionArgs]] = None,
filter: Optional[str] = None,
include_children: Optional[bool] = None,
intercept_children: Optional[bool] = None,
name: Optional[str] = None,
org_id: Optional[str] = None,
writer_identity: Optional[str] = None) -> OrganizationSink
func GetOrganizationSink(ctx *Context, name string, id IDInput, state *OrganizationSinkState, opts ...ResourceOption) (*OrganizationSink, error)
public static OrganizationSink Get(string name, Input<string> id, OrganizationSinkState? state, CustomResourceOptions? opts = null)
public static OrganizationSink get(String name, Output<String> id, OrganizationSinkState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Bigquery
Options OrganizationSink Bigquery Options - Options that affect sinks exporting data to BigQuery. Structure documented below.
- Description string
- A description of this sink. The maximum length of the description is 8000 characters.
- Destination string
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- Disabled bool
- If set to True, then this sink is disabled and it does not export any log entries.
- Exclusions
List<Organization
Sink Exclusion> - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - Filter string
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- Include
Children bool - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- Intercept
Children bool - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- Name string
- The name of the logging sink.
- Org
Id string - The numeric ID of the organization to be exported to the sink.
- Writer
Identity string - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- Bigquery
Options OrganizationSink Bigquery Options Args - Options that affect sinks exporting data to BigQuery. Structure documented below.
- Description string
- A description of this sink. The maximum length of the description is 8000 characters.
- Destination string
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- Disabled bool
- If set to True, then this sink is disabled and it does not export any log entries.
- Exclusions
[]Organization
Sink Exclusion Args - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - Filter string
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- Include
Children bool - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- Intercept
Children bool - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- Name string
- The name of the logging sink.
- Org
Id string - The numeric ID of the organization to be exported to the sink.
- Writer
Identity string - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- bigquery
Options OrganizationSink Bigquery Options - Options that affect sinks exporting data to BigQuery. Structure documented below.
- description String
- A description of this sink. The maximum length of the description is 8000 characters.
- destination String
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- disabled Boolean
- If set to True, then this sink is disabled and it does not export any log entries.
- exclusions
List<Organization
Sink Exclusion> - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - filter String
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- include
Children Boolean - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- intercept
Children Boolean - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- name String
- The name of the logging sink.
- org
Id String - The numeric ID of the organization to be exported to the sink.
- writer
Identity String - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- bigquery
Options OrganizationSink Bigquery Options - Options that affect sinks exporting data to BigQuery. Structure documented below.
- description string
- A description of this sink. The maximum length of the description is 8000 characters.
- destination string
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- disabled boolean
- If set to True, then this sink is disabled and it does not export any log entries.
- exclusions
Organization
Sink Exclusion[] - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - filter string
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- include
Children boolean - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- intercept
Children boolean - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- name string
- The name of the logging sink.
- org
Id string - The numeric ID of the organization to be exported to the sink.
- writer
Identity string - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- bigquery_
options OrganizationSink Bigquery Options Args - Options that affect sinks exporting data to BigQuery. Structure documented below.
- description str
- A description of this sink. The maximum length of the description is 8000 characters.
- destination str
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- disabled bool
- If set to True, then this sink is disabled and it does not export any log entries.
- exclusions
Sequence[Organization
Sink Exclusion Args] - Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - filter str
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- include_
children bool - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- intercept_
children bool - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- name str
- The name of the logging sink.
- org_
id str - The numeric ID of the organization to be exported to the sink.
- writer_
identity str - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
- bigquery
Options Property Map - Options that affect sinks exporting data to BigQuery. Structure documented below.
- description String
- A description of this sink. The maximum length of the description is 8000 characters.
- destination String
The destination of the sink (or, in other words, where logs are written to). Can be a Cloud Storage bucket, a PubSub topic, a BigQuery dataset, a Cloud Logging bucket, or a Google Cloud project. Examples:
storage.googleapis.com/[GCS_BUCKET]
bigquery.googleapis.com/projects/[PROJECT_ID]/datasets/[DATASET]
pubsub.googleapis.com/projects/[PROJECT_ID]/topics/[TOPIC_ID]
logging.googleapis.com/projects/[PROJECT_ID]/locations/global/buckets/[BUCKET_ID]
logging.googleapis.com/projects/[PROJECT_ID]
The writer associated with the sink must have access to write to the above resource.
- disabled Boolean
- If set to True, then this sink is disabled and it does not export any log entries.
- exclusions List<Property Map>
- Log entries that match any of the exclusion filters will not be exported. If a log entry is matched by both
filter
and one ofexclusions.filter
, it will not be exported. Can be repeated multiple times for multiple exclusions. Structure is documented below. - filter String
- The filter to apply when exporting logs. Only log entries that match the filter are exported. See Advanced Log Filters for information on how to write a filter.
- include
Children Boolean - Whether or not to include children organizations in the sink export. If true, logs associated with child projects are also exported; otherwise only logs relating to the provided organization are included.
- intercept
Children Boolean - Whether or not to intercept logs from child projects. If true, matching logs will not match with sinks in child resources, except _Required sinks. This sink will be visible to child resources when listing sinks.
- name String
- The name of the logging sink.
- org
Id String - The numeric ID of the organization to be exported to the sink.
- writer
Identity String - The identity associated with this sink. This identity must be granted write access to the
configured
destination
.
Supporting Types
OrganizationSinkBigqueryOptions, OrganizationSinkBigqueryOptionsArgs
- Use
Partitioned boolTables - Whether to use BigQuery's partition tables. By default, Logging creates dated tables based on the log entries' timestamps, e.g. syslog_20170523. With partitioned tables the date suffix is no longer present and special query syntax has to be used instead. In both cases, tables are sharded based on UTC timezone.
- Use
Partitioned boolTables - Whether to use BigQuery's partition tables. By default, Logging creates dated tables based on the log entries' timestamps, e.g. syslog_20170523. With partitioned tables the date suffix is no longer present and special query syntax has to be used instead. In both cases, tables are sharded based on UTC timezone.
- use
Partitioned BooleanTables - Whether to use BigQuery's partition tables. By default, Logging creates dated tables based on the log entries' timestamps, e.g. syslog_20170523. With partitioned tables the date suffix is no longer present and special query syntax has to be used instead. In both cases, tables are sharded based on UTC timezone.
- use
Partitioned booleanTables - Whether to use BigQuery's partition tables. By default, Logging creates dated tables based on the log entries' timestamps, e.g. syslog_20170523. With partitioned tables the date suffix is no longer present and special query syntax has to be used instead. In both cases, tables are sharded based on UTC timezone.
- use_
partitioned_ booltables - Whether to use BigQuery's partition tables. By default, Logging creates dated tables based on the log entries' timestamps, e.g. syslog_20170523. With partitioned tables the date suffix is no longer present and special query syntax has to be used instead. In both cases, tables are sharded based on UTC timezone.
- use
Partitioned BooleanTables - Whether to use BigQuery's partition tables. By default, Logging creates dated tables based on the log entries' timestamps, e.g. syslog_20170523. With partitioned tables the date suffix is no longer present and special query syntax has to be used instead. In both cases, tables are sharded based on UTC timezone.
OrganizationSinkExclusion, OrganizationSinkExclusionArgs
- Filter string
- An advanced logs filter that matches the log entries to be excluded. By using the sample function, you can exclude less than 100% of the matching log entries. See Advanced Log Filters for information on how to write a filter.
- Name string
- A client-assigned identifier, such as
load-balancer-exclusion
. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric. - Description string
- A description of this exclusion.
- Disabled bool
- If set to True, then this exclusion is disabled and it does not exclude any log entries.
- Filter string
- An advanced logs filter that matches the log entries to be excluded. By using the sample function, you can exclude less than 100% of the matching log entries. See Advanced Log Filters for information on how to write a filter.
- Name string
- A client-assigned identifier, such as
load-balancer-exclusion
. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric. - Description string
- A description of this exclusion.
- Disabled bool
- If set to True, then this exclusion is disabled and it does not exclude any log entries.
- filter String
- An advanced logs filter that matches the log entries to be excluded. By using the sample function, you can exclude less than 100% of the matching log entries. See Advanced Log Filters for information on how to write a filter.
- name String
- A client-assigned identifier, such as
load-balancer-exclusion
. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric. - description String
- A description of this exclusion.
- disabled Boolean
- If set to True, then this exclusion is disabled and it does not exclude any log entries.
- filter string
- An advanced logs filter that matches the log entries to be excluded. By using the sample function, you can exclude less than 100% of the matching log entries. See Advanced Log Filters for information on how to write a filter.
- name string
- A client-assigned identifier, such as
load-balancer-exclusion
. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric. - description string
- A description of this exclusion.
- disabled boolean
- If set to True, then this exclusion is disabled and it does not exclude any log entries.
- filter str
- An advanced logs filter that matches the log entries to be excluded. By using the sample function, you can exclude less than 100% of the matching log entries. See Advanced Log Filters for information on how to write a filter.
- name str
- A client-assigned identifier, such as
load-balancer-exclusion
. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric. - description str
- A description of this exclusion.
- disabled bool
- If set to True, then this exclusion is disabled and it does not exclude any log entries.
- filter String
- An advanced logs filter that matches the log entries to be excluded. By using the sample function, you can exclude less than 100% of the matching log entries. See Advanced Log Filters for information on how to write a filter.
- name String
- A client-assigned identifier, such as
load-balancer-exclusion
. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric. - description String
- A description of this exclusion.
- disabled Boolean
- If set to True, then this exclusion is disabled and it does not exclude any log entries.
Import
Organization-level logging sinks can be imported using this format:
organizations/{{organization_id}}/sinks/{{sink_id}}
When using the pulumi import
command, organization-level logging sinks can be imported using one of the formats above. For example:
$ pulumi import gcp:logging/organizationSink:OrganizationSink default organizations/{{organization_id}}/sinks/{{sink_id}}
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Google Cloud (GCP) Classic pulumi/pulumi-gcp
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
google-beta
Terraform Provider.