Practice the vocabulary for reading and explaining Terraform plan output: resource changes, additions, modifications, and destruction.
0 / 8 completed
1 / 8
In a Terraform plan output, what does the '+' symbol indicate?
In Terraform plan output: '+' = create (green), '~' = update in-place (yellow), '-' = destroy (red), '-/+' = destroy and re-create. Recognizing these symbols is essential for reviewing plans before applying.
2 / 8
What does 'terraform plan -out=plan.tfplan' do?
'-out' saves the plan as a binary file. This is a best practice in CI/CD: 'plan' saves what will happen, 'apply plan.tfplan' executes exactly that plan — no risk of changes between planning and applying.
3 / 8
What does 'known after apply' mean in a Terraform plan output?
'Known after apply' means Terraform cannot compute the value until the resource exists — for example, a load balancer's DNS name or a database instance's assigned IP. It appears as '(known after apply)' in plan output.
4 / 8
How would you explain this Terraform plan line to a colleague? '# aws_instance.web will be destroyed'
Destruction in Terraform is permanent. Always scrutinize lines showing '-' or 'will be destroyed' carefully before applying. Common causes: removing a resource block, changing a force-new attribute, or running 'terraform destroy'.
5 / 8
What does 'forces replacement' mean in Terraform plan output?
Some attributes cannot be updated in place (e.g., AWS EC2 AMI ID, RDS engine version). Changing them forces Terraform to destroy the old resource and create a new one. This can cause downtime and data loss — always verify before applying.
6 / 8
What is the correct command to see what changes Terraform would make to existing infrastructure without applying them?
'terraform plan' compares your configuration with the current state and shows what changes would be made. It is the essential review step before 'terraform apply'. Always run it and review the output carefully.
7 / 8
In a Terraform plan, what does this line communicate? 'Plan: 3 to add, 2 to change, 1 to destroy.'
The plan summary shows the net effect: 3 new resources created, 2 modified in-place, 1 permanently deleted. Review the destruction especially carefully — it may indicate an unintended change.
8 / 8
What does 'terraform state' command help you understand?
Terraform state (terraform.tfstate) records what Terraform knows about your infrastructure. 'terraform state list' shows managed resources; 'terraform state show ' shows details. Understanding state is critical for debugging plan discrepancies.