Welcome to Pulumi Registry, your window into the cloud. Read the announcement.

Google Cloud (GCP) Classic

v5.25.0 published on Tuesday, Oct 19, 2021 by Pulumi

Google Cloud Functions

View Code Deploy

An example of deploying an HTTP Google Cloud Function endpoint using TypeScript.


  1. Ensure you have the latest Node.js and NPM
  2. Install the Pulumi CLI
  3. Configure Pulumi to access your GCP account

Running the App

  1. Restore NPM dependencies:

    $ npm install
  2. Create a new stack:

    $ pulumi stack init gcp-fn
  3. Configure your GCP project and region:

    $ pulumi config set gcp:project <projectname> 
    $ pulumi config set gcp:region <region>
  4. Run pulumi up to preview and deploy changes:

    $ pulumi up
    Previewing changes:
    Performing changes:
    info: 6 changes performed:
        + 6 resources created
    Update duration: 39.65130324s
  5. Check the deployed function endpoint:

    $ pulumi stack output url
    $ curl "$(pulumi stack output url)"
    Greetings from Google Cloud Functions!
  6. Clean up your GCP and Pulumi resources:

    $ pulumi destroy
    $ pulumi stack rm