🔥 3-day streak
HashiCorp Certified: Terraform Associate (004)103 / 150
Question 103 of 150
A teammate refactored a configuration by wrapping a single existing resource in a for_each block. The resource was previously declared as `aws_s3_bucket.logs` and is now addressed as `aws_s3_bucket.logs["prod"]`. Running `terraform plan` shows Terraform wants to destroy the old bucket and create a new one. Which command updates the state so the existing bucket is preserved and matched to its new address?
Reviewed for accuracy · Report an issueNext question