$ ./guess_the_languageDevOps
DevOps · medium · #244

What does -replace do here?

terraform apply -replace="aws_instance.web"
  1. Renames the resource in state
  2. Forces that instance to be recreated
  3. Swaps it for a cheaper instance type
  4. Replaces only its tags in place
-replace plans a destroy-and-create for that one resource even though its config is unchanged; it supersedes terraform taint.
Play DevOps ▸