TA-002-P · Question #67
How can terraform plan aid in the development process?
The correct answer is A. Validates your expectations against the execution plan without permanently modifying. The 'terraform plan' command helps in development by showing a preview of the changes Terraform will make to infrastructure without actually applying them, allowing validation of configuration before deployment.
Question
How can terraform plan aid in the development process?
Options
- AValidates your expectations against the execution plan without permanently modifying
- BInitializes your working directory containing your Terraform configuration files
- CFormats your Terraform configuration files
- DReconciles Terraform's state against deployed resources and permanently modifies state
How the community answered
(20 responses)- A90% (18)
- B5% (1)
- C5% (1)
Why each option
The 'terraform plan' command helps in development by showing a preview of the changes Terraform will make to infrastructure without actually applying them, allowing validation of configuration before deployment.
'terraform plan' is crucial for development as it generates an execution plan detailing what actions (create, update, destroy) Terraform will perform to reach the desired state defined in the configuration, without making any actual changes to the real infrastructure. This allows developers to verify their configuration and anticipate potential issues.
'terraform init' initializes the working directory, downloads providers, and sets up backend configuration.
'terraform fmt' formats Terraform configuration files to a canonical style.
'terraform refresh' reconciles state, and 'terraform apply' modifies state and infrastructure; 'plan' does not permanently modify.
Concept tested: Terraform plan command purpose
Source: https://developer.hashicorp.com/terraform/cli/commands/plan
Topics
Community Discussion
No community discussion yet for this question.