Terraform Associate Practice Exam

Session length

1 / 400

In which situation will Terraform not apply changes made directly on the cloud console?

When the Terraform configuration is updated

When a state file reflects the current configuration

When the state file reflects the current configuration, Terraform will not apply changes made directly on the cloud console because the state file is considered the authoritative source of truth for the infrastructure that Terraform manages. The state file contains a record of the resources that Terraform has created and their current configurations.

If changes are made directly in the cloud console, Terraform will detect those changes during its next operation. However, if the state file accurately reflects the latest configuration of the resources, Terraform will recognize that the infrastructure is already in the desired state as defined in the state file. Consequently, Terraform will not apply any changes since it perceives that there is no divergence between what it manages and the actual state of the infrastructure.

This mechanism reinforces the importance of managing infrastructure with Terraform and discourages manual changes that could lead to inconsistencies between the state file and the actual infrastructure. It promotes a declarative infrastructure as code approach, where all changes should go through Terraform to maintain synchronization and manageability.

Get further explanation with Examzify DeepDiveBeta

When there are conflicts with existing resources

When Terraform has not been exported correctly

Next Question
Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy