Terraform Associate Exam QuestionsBrowse all questions from this exam

Terraform Associate Exam - Question 285


When do you need to explicitly execute terraform refresh-only?

Show Answer
Correct Answer: D

The correct option is 'None of the above'. The 'terraform refresh-only' command doesn't need to be executed explicitly under typical conditions before any of the other commands listed (terraform plan, terraform apply, or terraform import). This command is used to reconcile the state file with the real-world infrastructure without making any changes to that infrastructure.

Discussion

1 comment
Sign in to comment
vindi135Option: D
May 26, 2024

D. none of the above. The question isn't fully correct, the command is terraform apply -refresh-only. You'd only want to do this in place of terraform taint, when you'd want the state to be the same as the real world infrastructure

Alandt
Jul 23, 2024

init mate? (London accent)