Editing Terraform destroy
Jump to navigation
Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
− | + | * https://www.terraform.io/docs/cli/commands/destroy.html | |
− | |||
− | + | <pre> | |
+ | terraform destroy | ||
+ | aws_instance.app_server: Refreshing state... [id=i-0598bc37b772faaa3] | ||
− | + | Terraform used the selected providers to generate the following execution plan. Resource actions are indicated with the | |
− | + | following symbols: | |
− | + | - destroy | |
− | |||
− | |||
− | |||
− | + | Terraform will perform the following actions: | |
− | |||
− | |||
− | == | + | # aws_instance.app_server will be destroyed |
− | + | - resource "aws_instance" "app_server" { | |
− | + | - ami = "ami-830c94e3" -> null | |
− | + | - arn = "arn:aws:ec2:us-west-2:72859226533:instance/i-0598bc37b772faaa3" -> null | |
− | + | - associate_public_ip_address = true -> null | |
− | + | - availability_zone = "us-west-2a" -> null | |
− | + | - cpu_core_count = 1 -> null | |
− | + | - cpu_threads_per_core = 1 -> null | |
+ | .../... | ||
− | + | Plan: 0 to add, 0 to change, 1 to destroy. | |
− | |||
− | |||
− | |||
− | |||
− | + | Do you really want to destroy all resources? | |
− | + | Terraform will destroy all your managed infrastructure, as shown above. | |
− | + | There is no undo. Only 'yes' will be accepted to confirm. | |
− | == | + | Enter a value: yes |
− | + | ||
+ | aws_instance.app_server: Destroying... [id=i-0598bc37b772faaa3] | ||
+ | aws_instance.app_server: Still destroying... [id=i-0598bc37b772faaa3, 10s elapsed] | ||
+ | aws_instance.app_server: Destruction complete after 30s | ||
+ | |||
+ | Destroy complete! Resources: 1 destroyed. | ||
+ | </pre> | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | [[terraform destroy --help]] | ||
+ | |||
+ | ==See also == | ||
+ | * {{terraform cmd}} | ||
− | |||
− | |||
− | |||
[[Category:Terraform]] | [[Category:Terraform]] |
Advertising: