Though the Answer is "D", he is the tricky aspect
Lets just say, we provisioned Infrastructure through Terraform using config files, then someone goes to CLI and makes a manual change. Once you apply terraform Refresh, you no longer have all the information in statefile which is provisioned through terrform.
Just like option C, you make changes to confi files and you apply, desired state, current state are same and state file does represents the desired state expressed by the Terraform code files.
D. A state file represents a source of truth for resources provisioned with Terraform
A key benefit of the Terraform state file is that it represents a source of truth for resources provisioned with Terraform. The state file is used to keep track of the current state of the infrastructure resources that are being managed by Terraform. It contains information about the resources, their properties, and the dependencies between them.
The state file is used by Terraform to determine what changes need to be made to the infrastructure to reach the desired state defined in the configuration files.
A. A state file can be used to schedule recurring infrastructure tasks, is not a benefit of state file.
B. A state file represents a source of truth for resources provisioned with a public cloud console, is not a benefit of state file.
C. A state file represents the desired state expressed by the Terraform code files, is not a benefit of state file.
The idea of a state file is to operate as a source of truth. If the infrastructure deviates from that it is capable of fixing that.
upvoted 3 times
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
090200f
3 months, 3 weeks agoBlitz123
9 months, 4 weeks agocamps
1 year, 7 months agoAgil09
1 year, 10 months agoZeppoonstream
1 year, 10 months agoNirms
1 year, 10 months agogekkehenk
1 year, 10 months ago