2023-06-16 14:10:53 -07:00
---
title_tag: Destroy the Stack | Google Cloud
meta_desc: This page provides an overview of how to destroy a Pulumi stack of a Google Cloud (GCP) project.
title: Destroy stack
h1: "Pulumi & Google Cloud: Destroy stack"
weight: 8
menu:
clouds:
parent: google-cloud-get-started
identifier: gcp-destroy-stack
aliases:
- /docs/quickstart/gcp/destroy-stack/
- /docs/get-started/gcp/destroy-stack/
---
2023-08-04 10:59:33 -07:00
Now that you've seen how to deploy and manage cloud resources with Pulumi, let's clean up by tearing down all of the resources that belong to this stack.
2023-06-16 14:10:53 -07:00
2023-08-04 10:59:33 -07:00
To do so, run the following:
2023-06-16 14:10:53 -07:00
```bash
$ pulumi destroy
```
2023-08-04 10:59:33 -07:00
Again you'll be presented with a preview of the changes to be made. Choose `yes` . The destroy operation may take few moments, as Pulumi waits for all resources are to be deleted before considering the operation complete:
2023-06-16 14:10:53 -07:00
```
2023-08-04 10:59:33 -07:00
Previewing destroy (dev)
2023-06-16 14:10:53 -07:00
2023-08-04 10:59:33 -07:00
Type Name Plan
- pulumi:pulumi:Stack quickstart-dev delete
- ├─ gcp:storage:BucketIAMBinding my-bucket-binding delete
- ├─ gcp:storage:BucketObject index.html delete
- └─ gcp:storage:Bucket my-bucket delete
2023-06-16 14:10:53 -07:00
Outputs:
2023-08-04 10:59:33 -07:00
- bucketEndpoint: "http://storage.googleapis.com/my-bucket-daa12be/index.html-a52debd"
- bucketName : "gs://my-bucket-daa12be"
2023-06-16 14:10:53 -07:00
Resources:
- 4 to delete
Do you want to perform this destroy? yes
2023-08-04 10:59:33 -07:00
Destroying (dev)
2023-06-16 14:10:53 -07:00
2023-08-04 10:59:33 -07:00
Type Name Status
- pulumi:pulumi:Stack quickstart-dev deleted
- ├─ gcp:storage:BucketIAMBinding my-bucket-binding deleted (6s)
- ├─ gcp:storage:BucketObject index.html deleted (0.78s)
- └─ gcp:storage:Bucket my-bucket deleted (1s)
2023-06-16 14:10:53 -07:00
Outputs:
2023-08-04 10:59:33 -07:00
- bucketEndpoint: "http://storage.googleapis.com/my-bucket-daa12be/index.html-a52debd"
- bucketName : "gs://my-bucket-daa12be"
2023-06-16 14:10:53 -07:00
Resources:
- 4 deleted
2023-08-04 10:59:33 -07:00
Duration: 9s
2023-06-16 14:10:53 -07:00
```
2023-08-04 10:59:33 -07:00
Optionally, to delete the stack itself, you can also run [`pulumi stack rm` ](/docs/cli/commands/pulumi_stack_rm ). Doing so removes the stack entirely from the Pulumi Cloud, along with all of its update history.
2023-06-16 14:10:53 -07:00
Congratulations! You've successfully provisioned some cloud resources using Pulumi. By completing this guide you have successfully:
- Created a Pulumi new project.
- Provisioned a new storage bucket.
- Added an `index.html` file to your bucket.
2023-08-04 10:59:33 -07:00
- Served the file as a static website.
2023-06-16 14:10:53 -07:00
- Destroyed the resources you've provisioned.
On the next page, we have a collection of examples and tutorials that you can deploy as they are or use them as a foundation for your own applications and infrastructure projects.
{{< get-started-stepper > }}