Function

Creates a new Cloud Function. For more information see the official documentation and API.

Warning: As of November 1, 2019, newly created Functions are private-by-default and will require appropriate IAM permissions to be invoked. See below examples for how to set up the appropriate permissions, or view the Cloud Functions IAM resources for Cloud Functions.

Create a Function Resource

def Function(resource_name, opts=None, available_memory_mb=None, description=None, entry_point=None, environment_variables=None, event_trigger=None, https_trigger_url=None, ingress_settings=None, labels=None, max_instances=None, name=None, project=None, region=None, runtime=None, service_account_email=None, source_archive_bucket=None, source_archive_object=None, source_repository=None, timeout=None, trigger_http=None, vpc_connector=None, vpc_connector_egress_settings=None, __props__=None);
func NewFunction(ctx *Context, name string, args FunctionArgs, opts ...ResourceOption) (*Function, error)
public Function(string name, FunctionArgs args, CustomResourceOptions? opts = null)
name string
The unique name of the resource.
args FunctionArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
opts ResourceOptions
A bag of options that control this resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args FunctionArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args FunctionArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

Function Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The Function resource accepts the following input properties:

Runtime string

The runtime in which the function is going to run. Eg. "nodejs8", "nodejs10", "python37", "go111".

AvailableMemoryMb int

Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.

Description string

Description of the function.

EntryPoint string

Name of the function that will be executed when the Google Cloud Function is triggered.

EnvironmentVariables Dictionary<string, object>

A set of key/value environment variable pairs to assign to the function.

EventTrigger FunctionEventTriggerArgs

A source that fires events in response to a condition in another service. Structure is documented below. Cannot be used with trigger_http.

HttpsTriggerUrl string

URL which triggers function execution. Returned only if trigger_http is used.

IngressSettings string

String value that controls what traffic can reach the function. Allowed values are ALLOW_ALL and ALLOW_INTERNAL_ONLY. Changes to this field will recreate the cloud function.

Labels Dictionary<string, object>

A set of key/value label pairs to assign to the function. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements.

MaxInstances int

The limit on the maximum number of function instances that may coexist at a given time.

Name string

A user-defined name of the function. Function names must be unique globally.

Project string

Project of the function. If it is not provided, the provider project is used.

Region string

Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.

ServiceAccountEmail string

If provided, the self-provided service account to run the function with.

SourceArchiveBucket string

The GCS bucket containing the zip archive which contains the function.

SourceArchiveObject string

The source archive object (file) in archive bucket.

SourceRepository FunctionSourceRepositoryArgs

Represents parameters related to source repository where a function is hosted. Cannot be set alongside source_archive_bucket or source_archive_object. Structure is documented below.

Timeout int

Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.

TriggerHttp bool

Boolean variable. Any HTTP request (of a supported type) to the endpoint will trigger function execution. Supported HTTP request types are: POST, PUT, GET, DELETE, and OPTIONS. Endpoint is returned as https_trigger_url. Cannot be used with trigger_bucket and trigger_topic.

VpcConnector string

The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is projects/*/locations/*/connectors/*.

VpcConnectorEgressSettings string

The egress settings for the connector, controlling what traffic is diverted through it. Allowed values are ALL_TRAFFIC and PRIVATE_RANGES_ONLY. Defaults to PRIVATE_RANGES_ONLY. If unset, this field preserves the previously set value.

Runtime string

The runtime in which the function is going to run. Eg. "nodejs8", "nodejs10", "python37", "go111".

AvailableMemoryMb int

Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.

Description string

Description of the function.

EntryPoint string

Name of the function that will be executed when the Google Cloud Function is triggered.

EnvironmentVariables map[string]interface{}

A set of key/value environment variable pairs to assign to the function.

EventTrigger FunctionEventTrigger

A source that fires events in response to a condition in another service. Structure is documented below. Cannot be used with trigger_http.

HttpsTriggerUrl string

URL which triggers function execution. Returned only if trigger_http is used.

IngressSettings string

String value that controls what traffic can reach the function. Allowed values are ALLOW_ALL and ALLOW_INTERNAL_ONLY. Changes to this field will recreate the cloud function.

Labels map[string]interface{}

A set of key/value label pairs to assign to the function. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements.

MaxInstances int

The limit on the maximum number of function instances that may coexist at a given time.

Name string

A user-defined name of the function. Function names must be unique globally.

Project string

Project of the function. If it is not provided, the provider project is used.

Region string

Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.

ServiceAccountEmail string

If provided, the self-provided service account to run the function with.

SourceArchiveBucket string

The GCS bucket containing the zip archive which contains the function.

SourceArchiveObject string

The source archive object (file) in archive bucket.

SourceRepository FunctionSourceRepository

Represents parameters related to source repository where a function is hosted. Cannot be set alongside source_archive_bucket or source_archive_object. Structure is documented below.

Timeout int

Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.

TriggerHttp bool

Boolean variable. Any HTTP request (of a supported type) to the endpoint will trigger function execution. Supported HTTP request types are: POST, PUT, GET, DELETE, and OPTIONS. Endpoint is returned as https_trigger_url. Cannot be used with trigger_bucket and trigger_topic.

VpcConnector string

The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is projects/*/locations/*/connectors/*.

VpcConnectorEgressSettings string

The egress settings for the connector, controlling what traffic is diverted through it. Allowed values are ALL_TRAFFIC and PRIVATE_RANGES_ONLY. Defaults to PRIVATE_RANGES_ONLY. If unset, this field preserves the previously set value.

runtime string

The runtime in which the function is going to run. Eg. "nodejs8", "nodejs10", "python37", "go111".

availableMemoryMb number

Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.

description string

Description of the function.

entryPoint string

Name of the function that will be executed when the Google Cloud Function is triggered.

environmentVariables {[key: string]: any}

A set of key/value environment variable pairs to assign to the function.

eventTrigger FunctionEventTrigger

A source that fires events in response to a condition in another service. Structure is documented below. Cannot be used with trigger_http.

httpsTriggerUrl string

URL which triggers function execution. Returned only if trigger_http is used.

ingressSettings string

String value that controls what traffic can reach the function. Allowed values are ALLOW_ALL and ALLOW_INTERNAL_ONLY. Changes to this field will recreate the cloud function.

labels {[key: string]: any}

A set of key/value label pairs to assign to the function. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements.

maxInstances number

The limit on the maximum number of function instances that may coexist at a given time.

name string

A user-defined name of the function. Function names must be unique globally.

project string

Project of the function. If it is not provided, the provider project is used.

region string

Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.

serviceAccountEmail string

If provided, the self-provided service account to run the function with.

sourceArchiveBucket string

The GCS bucket containing the zip archive which contains the function.

sourceArchiveObject string

The source archive object (file) in archive bucket.

sourceRepository FunctionSourceRepository

Represents parameters related to source repository where a function is hosted. Cannot be set alongside source_archive_bucket or source_archive_object. Structure is documented below.

timeout number

Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.

triggerHttp boolean

Boolean variable. Any HTTP request (of a supported type) to the endpoint will trigger function execution. Supported HTTP request types are: POST, PUT, GET, DELETE, and OPTIONS. Endpoint is returned as https_trigger_url. Cannot be used with trigger_bucket and trigger_topic.

vpcConnector string

The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is projects/*/locations/*/connectors/*.

vpcConnectorEgressSettings string

The egress settings for the connector, controlling what traffic is diverted through it. Allowed values are ALL_TRAFFIC and PRIVATE_RANGES_ONLY. Defaults to PRIVATE_RANGES_ONLY. If unset, this field preserves the previously set value.

runtime str

The runtime in which the function is going to run. Eg. "nodejs8", "nodejs10", "python37", "go111".

available_memory_mb float

Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.

description str

Description of the function.

entry_point str

Name of the function that will be executed when the Google Cloud Function is triggered.

environment_variables Dict[str, Any]

A set of key/value environment variable pairs to assign to the function.

event_trigger Dict[FunctionEventTrigger]

A source that fires events in response to a condition in another service. Structure is documented below. Cannot be used with trigger_http.

https_trigger_url str

URL which triggers function execution. Returned only if trigger_http is used.

ingress_settings str

String value that controls what traffic can reach the function. Allowed values are ALLOW_ALL and ALLOW_INTERNAL_ONLY. Changes to this field will recreate the cloud function.

labels Dict[str, Any]

A set of key/value label pairs to assign to the function. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements.

max_instances float

The limit on the maximum number of function instances that may coexist at a given time.

name str

A user-defined name of the function. Function names must be unique globally.

project str

Project of the function. If it is not provided, the provider project is used.

region str

Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.

service_account_email str

If provided, the self-provided service account to run the function with.

source_archive_bucket str

The GCS bucket containing the zip archive which contains the function.

source_archive_object str

The source archive object (file) in archive bucket.

source_repository Dict[FunctionSourceRepository]

Represents parameters related to source repository where a function is hosted. Cannot be set alongside source_archive_bucket or source_archive_object. Structure is documented below.

timeout float

Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.

trigger_http bool

Boolean variable. Any HTTP request (of a supported type) to the endpoint will trigger function execution. Supported HTTP request types are: POST, PUT, GET, DELETE, and OPTIONS. Endpoint is returned as https_trigger_url. Cannot be used with trigger_bucket and trigger_topic.

vpc_connector str

The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is projects/*/locations/*/connectors/*.

vpc_connector_egress_settings str

The egress settings for the connector, controlling what traffic is diverted through it. Allowed values are ALL_TRAFFIC and PRIVATE_RANGES_ONLY. Defaults to PRIVATE_RANGES_ONLY. If unset, this field preserves the previously set value.

Outputs

All input properties are implicitly available as output properties. Additionally, the Function resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.

Look up an Existing Function Resource

Get an existing Function 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?: FunctionState, opts?: CustomResourceOptions): Function
static get(resource_name, id, opts=None, available_memory_mb=None, description=None, entry_point=None, environment_variables=None, event_trigger=None, https_trigger_url=None, ingress_settings=None, labels=None, max_instances=None, name=None, project=None, region=None, runtime=None, service_account_email=None, source_archive_bucket=None, source_archive_object=None, source_repository=None, timeout=None, trigger_http=None, vpc_connector=None, vpc_connector_egress_settings=None, __props__=None);
func GetFunction(ctx *Context, name string, id IDInput, state *FunctionState, opts ...ResourceOption) (*Function, error)
public static Function Get(string name, Input<string> id, FunctionState? state, CustomResourceOptions? opts = null)
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.

The following state arguments are supported:

AvailableMemoryMb int

Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.

Description string

Description of the function.

EntryPoint string

Name of the function that will be executed when the Google Cloud Function is triggered.

EnvironmentVariables Dictionary<string, object>

A set of key/value environment variable pairs to assign to the function.

EventTrigger FunctionEventTriggerArgs

A source that fires events in response to a condition in another service. Structure is documented below. Cannot be used with trigger_http.

HttpsTriggerUrl string

URL which triggers function execution. Returned only if trigger_http is used.

IngressSettings string

String value that controls what traffic can reach the function. Allowed values are ALLOW_ALL and ALLOW_INTERNAL_ONLY. Changes to this field will recreate the cloud function.

Labels Dictionary<string, object>

A set of key/value label pairs to assign to the function. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements.

MaxInstances int

The limit on the maximum number of function instances that may coexist at a given time.

Name string

A user-defined name of the function. Function names must be unique globally.

Project string

Project of the function. If it is not provided, the provider project is used.

Region string

Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.

Runtime string

The runtime in which the function is going to run. Eg. "nodejs8", "nodejs10", "python37", "go111".

ServiceAccountEmail string

If provided, the self-provided service account to run the function with.

SourceArchiveBucket string

The GCS bucket containing the zip archive which contains the function.

SourceArchiveObject string

The source archive object (file) in archive bucket.

SourceRepository FunctionSourceRepositoryArgs

Represents parameters related to source repository where a function is hosted. Cannot be set alongside source_archive_bucket or source_archive_object. Structure is documented below.

Timeout int

Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.

TriggerHttp bool

Boolean variable. Any HTTP request (of a supported type) to the endpoint will trigger function execution. Supported HTTP request types are: POST, PUT, GET, DELETE, and OPTIONS. Endpoint is returned as https_trigger_url. Cannot be used with trigger_bucket and trigger_topic.

VpcConnector string

The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is projects/*/locations/*/connectors/*.

VpcConnectorEgressSettings string

The egress settings for the connector, controlling what traffic is diverted through it. Allowed values are ALL_TRAFFIC and PRIVATE_RANGES_ONLY. Defaults to PRIVATE_RANGES_ONLY. If unset, this field preserves the previously set value.

AvailableMemoryMb int

Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.

Description string

Description of the function.

EntryPoint string

Name of the function that will be executed when the Google Cloud Function is triggered.

EnvironmentVariables map[string]interface{}

A set of key/value environment variable pairs to assign to the function.

EventTrigger FunctionEventTrigger

A source that fires events in response to a condition in another service. Structure is documented below. Cannot be used with trigger_http.

HttpsTriggerUrl string

URL which triggers function execution. Returned only if trigger_http is used.

IngressSettings string

String value that controls what traffic can reach the function. Allowed values are ALLOW_ALL and ALLOW_INTERNAL_ONLY. Changes to this field will recreate the cloud function.

Labels map[string]interface{}

A set of key/value label pairs to assign to the function. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements.

MaxInstances int

The limit on the maximum number of function instances that may coexist at a given time.

Name string

A user-defined name of the function. Function names must be unique globally.

Project string

Project of the function. If it is not provided, the provider project is used.

Region string

Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.

Runtime string

The runtime in which the function is going to run. Eg. "nodejs8", "nodejs10", "python37", "go111".

ServiceAccountEmail string

If provided, the self-provided service account to run the function with.

SourceArchiveBucket string

The GCS bucket containing the zip archive which contains the function.

SourceArchiveObject string

The source archive object (file) in archive bucket.

SourceRepository FunctionSourceRepository

Represents parameters related to source repository where a function is hosted. Cannot be set alongside source_archive_bucket or source_archive_object. Structure is documented below.

Timeout int

Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.

TriggerHttp bool

Boolean variable. Any HTTP request (of a supported type) to the endpoint will trigger function execution. Supported HTTP request types are: POST, PUT, GET, DELETE, and OPTIONS. Endpoint is returned as https_trigger_url. Cannot be used with trigger_bucket and trigger_topic.

VpcConnector string

The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is projects/*/locations/*/connectors/*.

VpcConnectorEgressSettings string

The egress settings for the connector, controlling what traffic is diverted through it. Allowed values are ALL_TRAFFIC and PRIVATE_RANGES_ONLY. Defaults to PRIVATE_RANGES_ONLY. If unset, this field preserves the previously set value.

availableMemoryMb number

Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.

description string

Description of the function.

entryPoint string

Name of the function that will be executed when the Google Cloud Function is triggered.

environmentVariables {[key: string]: any}

A set of key/value environment variable pairs to assign to the function.

eventTrigger FunctionEventTrigger

A source that fires events in response to a condition in another service. Structure is documented below. Cannot be used with trigger_http.

httpsTriggerUrl string

URL which triggers function execution. Returned only if trigger_http is used.

ingressSettings string

String value that controls what traffic can reach the function. Allowed values are ALLOW_ALL and ALLOW_INTERNAL_ONLY. Changes to this field will recreate the cloud function.

labels {[key: string]: any}

A set of key/value label pairs to assign to the function. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements.

maxInstances number

The limit on the maximum number of function instances that may coexist at a given time.

name string

A user-defined name of the function. Function names must be unique globally.

project string

Project of the function. If it is not provided, the provider project is used.

region string

Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.

runtime string

The runtime in which the function is going to run. Eg. "nodejs8", "nodejs10", "python37", "go111".

serviceAccountEmail string

If provided, the self-provided service account to run the function with.

sourceArchiveBucket string

The GCS bucket containing the zip archive which contains the function.

sourceArchiveObject string

The source archive object (file) in archive bucket.

sourceRepository FunctionSourceRepository

Represents parameters related to source repository where a function is hosted. Cannot be set alongside source_archive_bucket or source_archive_object. Structure is documented below.

timeout number

Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.

triggerHttp boolean

Boolean variable. Any HTTP request (of a supported type) to the endpoint will trigger function execution. Supported HTTP request types are: POST, PUT, GET, DELETE, and OPTIONS. Endpoint is returned as https_trigger_url. Cannot be used with trigger_bucket and trigger_topic.

vpcConnector string

The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is projects/*/locations/*/connectors/*.

vpcConnectorEgressSettings string

The egress settings for the connector, controlling what traffic is diverted through it. Allowed values are ALL_TRAFFIC and PRIVATE_RANGES_ONLY. Defaults to PRIVATE_RANGES_ONLY. If unset, this field preserves the previously set value.

available_memory_mb float

Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.

description str

Description of the function.

entry_point str

Name of the function that will be executed when the Google Cloud Function is triggered.

environment_variables Dict[str, Any]

A set of key/value environment variable pairs to assign to the function.

event_trigger Dict[FunctionEventTrigger]

A source that fires events in response to a condition in another service. Structure is documented below. Cannot be used with trigger_http.

https_trigger_url str

URL which triggers function execution. Returned only if trigger_http is used.

ingress_settings str

String value that controls what traffic can reach the function. Allowed values are ALLOW_ALL and ALLOW_INTERNAL_ONLY. Changes to this field will recreate the cloud function.

labels Dict[str, Any]

A set of key/value label pairs to assign to the function. Label keys must follow the requirements at https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements.

max_instances float

The limit on the maximum number of function instances that may coexist at a given time.

name str

A user-defined name of the function. Function names must be unique globally.

project str

Project of the function. If it is not provided, the provider project is used.

region str

Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.

runtime str

The runtime in which the function is going to run. Eg. "nodejs8", "nodejs10", "python37", "go111".

service_account_email str

If provided, the self-provided service account to run the function with.

source_archive_bucket str

The GCS bucket containing the zip archive which contains the function.

source_archive_object str

The source archive object (file) in archive bucket.

source_repository Dict[FunctionSourceRepository]

Represents parameters related to source repository where a function is hosted. Cannot be set alongside source_archive_bucket or source_archive_object. Structure is documented below.

timeout float

Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.

trigger_http bool

Boolean variable. Any HTTP request (of a supported type) to the endpoint will trigger function execution. Supported HTTP request types are: POST, PUT, GET, DELETE, and OPTIONS. Endpoint is returned as https_trigger_url. Cannot be used with trigger_bucket and trigger_topic.

vpc_connector str

The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is projects/*/locations/*/connectors/*.

vpc_connector_egress_settings str

The egress settings for the connector, controlling what traffic is diverted through it. Allowed values are ALL_TRAFFIC and PRIVATE_RANGES_ONLY. Defaults to PRIVATE_RANGES_ONLY. If unset, this field preserves the previously set value.

Supporting Types

FunctionEventTrigger

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

EventType string

The type of event to observe. For example: "google.storage.object.finalize". See the documentation on calling Cloud Functions for a full reference of accepted triggers.

Resource string

Required. The name or partial URI of the resource from which to observe events. For example, "myBucket" or "projects/my-project/topics/my-topic"

FailurePolicy FunctionEventTriggerFailurePolicyArgs

Specifies policy for failed executions. Structure is documented below.

EventType string

The type of event to observe. For example: "google.storage.object.finalize". See the documentation on calling Cloud Functions for a full reference of accepted triggers.

Resource string

Required. The name or partial URI of the resource from which to observe events. For example, "myBucket" or "projects/my-project/topics/my-topic"

FailurePolicy FunctionEventTriggerFailurePolicy

Specifies policy for failed executions. Structure is documented below.

eventType string

The type of event to observe. For example: "google.storage.object.finalize". See the documentation on calling Cloud Functions for a full reference of accepted triggers.

resource string

Required. The name or partial URI of the resource from which to observe events. For example, "myBucket" or "projects/my-project/topics/my-topic"

failurePolicy FunctionEventTriggerFailurePolicy

Specifies policy for failed executions. Structure is documented below.

eventType str

The type of event to observe. For example: "google.storage.object.finalize". See the documentation on calling Cloud Functions for a full reference of accepted triggers.

resource str

Required. The name or partial URI of the resource from which to observe events. For example, "myBucket" or "projects/my-project/topics/my-topic"

failurePolicy Dict[FunctionEventTriggerFailurePolicy]

Specifies policy for failed executions. Structure is documented below.

FunctionEventTriggerFailurePolicy

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Retry bool

Whether the function should be retried on failure. Defaults to false.

Retry bool

Whether the function should be retried on failure. Defaults to false.

retry boolean

Whether the function should be retried on failure. Defaults to false.

retry bool

Whether the function should be retried on failure. Defaults to false.

FunctionSourceRepository

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

Url string

The URL pointing to the hosted repository where the function is defined. There are supported Cloud Source Repository URLs in the following formats:

DeployedUrl string
Url string

The URL pointing to the hosted repository where the function is defined. There are supported Cloud Source Repository URLs in the following formats:

DeployedUrl string
url string

The URL pointing to the hosted repository where the function is defined. There are supported Cloud Source Repository URLs in the following formats:

deployedUrl string
url str

The URL pointing to the hosted repository where the function is defined. There are supported Cloud Source Repository URLs in the following formats:

deployedUrl str

Package Details

Repository
https://github.com/pulumi/pulumi-gcp
License
Apache-2.0
Notes
This Pulumi package is based on the google-beta Terraform Provider.