What is @pulumi/gcp?
@pulumi/gcp is a Pulumi package that allows developers to create, deploy, and manage Google Cloud Platform (GCP) resources using Pulumi's infrastructure as code approach. It provides a wide range of functionalities to manage various GCP services such as Compute Engine, Cloud Storage, BigQuery, and more.
What are @pulumi/gcp's main functionalities?
Compute Engine
This feature allows you to create and manage Google Compute Engine instances. The code sample demonstrates how to create a new Compute Engine instance with specific configurations.
const gcp = require('@pulumi/gcp');
const compute = new gcp.compute.Instance('my-instance', {
machineType: 'f1-micro',
zone: 'us-central1-a',
bootDisk: {
initializeParams: {
image: 'debian-cloud/debian-9'
}
},
networkInterfaces: [{
network: 'default',
accessConfigs: [{}]
}]
});
Cloud Storage
This feature allows you to create and manage Google Cloud Storage buckets. The code sample demonstrates how to create a new Cloud Storage bucket with specific configurations.
const gcp = require('@pulumi/gcp');
const bucket = new gcp.storage.Bucket('my-bucket', {
location: 'US',
forceDestroy: true
});
BigQuery
This feature allows you to create and manage Google BigQuery datasets. The code sample demonstrates how to create a new BigQuery dataset with specific configurations.
const gcp = require('@pulumi/gcp');
const dataset = new gcp.bigquery.Dataset('my-dataset', {
datasetId: 'my_dataset',
friendlyName: 'My Dataset',
description: 'A sample dataset'
});
Cloud Functions
This feature allows you to create and manage Google Cloud Functions. The code sample demonstrates how to create a new Cloud Function with specific configurations.
const gcp = require('@pulumi/gcp');
const function = new gcp.cloudfunctions.Function('my-function', {
runtime: 'nodejs10',
entryPoint: 'helloWorld',
sourceArchiveBucket: bucket.name,
sourceArchiveObject: bucketObject.name,
triggerHttp: true
});
Other packages similar to @pulumi/gcp
@pulumi/aws
@pulumi/aws is a Pulumi package that allows developers to create, deploy, and manage Amazon Web Services (AWS) resources using Pulumi's infrastructure as code approach. It provides similar functionalities to @pulumi/gcp but for AWS services.
@pulumi/azure
@pulumi/azure is a Pulumi package that allows developers to create, deploy, and manage Microsoft Azure resources using Pulumi's infrastructure as code approach. It provides similar functionalities to @pulumi/gcp but for Azure services.
terraform
Terraform is an open-source infrastructure as code software tool created by HashiCorp. It allows users to define and provision data center infrastructure using a high-level configuration language. Terraform supports multiple cloud providers, including GCP, AWS, and Azure, making it a versatile alternative to @pulumi/gcp.
Google Cloud Platform Resource Provider
:warning: Pulumi is in private beta. This package may not work unless you are already participating.
Please visit pulumi.com to register for access.
The Google Cloud Platform (GCP) for Pulumi lets you use GCP resources in your cloud programs.
This package is meant for use with the Pulumi CLI. Please visit docs.pulumi.com for
installation instructions.