cloudfunctions

class pulumi_gcp.cloudfunctions.Function(resource_name, opts=None, available_memory_mb=None, description=None, entry_point=None, environment_variables=None, event_trigger=None, https_trigger_url=None, labels=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, __name__=None, __opts__=None)

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

Parameters:
  • resource_name (str) – The name of the resource.
  • opts (pulumi.ResourceOptions) – Options for the resource.
  • available_memory_mb (pulumi.Input[float]) – Memory (in MB), available to the function. Default value is 256MB. Allowed values are: 128MB, 256MB, 512MB, 1024MB, and 2048MB.
  • description (pulumi.Input[str]) – Description of the function.
  • entry_point (pulumi.Input[str]) – Name of the function that will be executed when the Google Cloud Function is triggered.
  • environment_variables (pulumi.Input[dict]) – A set of key/value environment variable pairs to assign to the function.
  • event_trigger (pulumi.Input[dict]) – 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 (pulumi.Input[str]) – URL which triggers function execution. Returned only if trigger_http is used.
  • labels (pulumi.Input[dict]) – A set of key/value label pairs to assign to the function.
  • name (pulumi.Input[str]) – A user-defined name of the function. Function names must be unique globally.
  • project (pulumi.Input[str]) – Project of the function. If it is not provided, the provider project is used.
  • region (pulumi.Input[str]) – Region of function. Currently can be only “us-central1”. If it is not provided, the provider region is used.
  • runtime (pulumi.Input[str]) – The runtime in which the function is going to run. If empty, defaults to "nodejs6".
  • service_account_email (pulumi.Input[str]) – If provided, the self-provided service account to run the function with.
  • source_archive_bucket (pulumi.Input[str]) – The GCS bucket containing the zip archive which contains the function.
  • source_archive_object (pulumi.Input[str]) – The source archive object (file) in archive bucket.
  • source_repository (pulumi.Input[dict]) – 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 (pulumi.Input[float]) – Timeout (in seconds) for the function. Default value is 60 seconds. Cannot be more than 540 seconds.
  • trigger_http (pulumi.Input[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.
available_memory_mb = None

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

description = None

Description of the function.

entry_point = None

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

environment_variables = None

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

event_trigger = None

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 = None

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

labels = None

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

name = None

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

project = None

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

region = None

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

runtime = None

The runtime in which the function is going to run. If empty, defaults to "nodejs6".

service_account_email = None

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

source_archive_bucket = None

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

source_archive_object = None

The source archive object (file) in archive bucket.

source_repository = None

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 = None

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

trigger_http = None

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.

translate_output_property(prop)

Provides subclasses of Resource an opportunity to translate names of output properties into a format of their choosing before writing those properties to the resource object.

Parameters:prop (str) – A property name.
Returns:A potentially transformed property name.
Return type:str
translate_input_property(prop)

Provides subclasses of Resource an opportunity to translate names of input properties into a format of their choosing before sending those properties to the Pulumi engine.

Parameters:prop (str) – A property name.
Returns:A potentially transformed property name.
Return type:str
class pulumi_gcp.cloudfunctions.GetFunctionResult(available_memory_mb=None, description=None, entry_point=None, environment_variables=None, event_triggers=None, https_trigger_url=None, labels=None, retry_on_failure=None, runtime=None, service_account_email=None, source_archive_bucket=None, source_archive_object=None, source_repositories=None, timeout=None, trigger_bucket=None, trigger_http=None, trigger_topic=None, id=None)

A collection of values returned by getFunction.

available_memory_mb = None

Available memory (in MB) to the function.

description = None

Description of the function.

entry_point = None

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

event_triggers = None

A source that fires events in response to a condition in another service. Structure is documented below.

https_trigger_url = None

If function is triggered by HTTP, trigger URL is set here.

labels = None

A map of labels applied to this function.

runtime = None

The runtime in which the function is running.

source_archive_bucket = None

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

source_archive_object = None

The source archive object (file) in archive bucket.

timeout = None

Function execution timeout (in seconds).

trigger_http = None

If function is triggered by HTTP, this boolean is set.

id = None

id is the provider-assigned unique ID for this managed resource.

pulumi_gcp.cloudfunctions.get_function(name=None, project=None, region=None, opts=None)

Get information about a Google Cloud Function. For more information see the official documentation and API.