Full end-to-end Terraform deployment pipeline — init, validate, plan, and apply for the Book Review App
Run the full deployment pipeline for the Book Review App infrastructure. This is the all-in-one command that takes you from zero to a running environment.
Work from the terraform/ directory.
Run:
terraform init -upgrade
If init fails (e.g., missing provider, bad backend config), diagnose and fix before continuing. Do not proceed with a broken init.
Run:
terraform fmt -recursive
Report any files that were reformatted.
Run:
terraform validate
Fix all errors before proceeding. Do not skip this step.
Before planning, scan all .tf files for:
0.0.0.0/0 inbound on any SG except the public ALB on 80/443publicly_accessible = true on any RDS resourcetags blocks on any resourceIf any violations are found, stop and list them. Do not proceed to plan until they are resolved.
Run:
terraform plan -var-file=terraform.tfvars -out=tfplan.out
Parse the plan and display:
Pause here. Show the plan summary and ask the user to confirm before applying: "Ready to apply the above plan. Type 'yes' to continue or 'no' to abort."
Do not proceed until the user explicitly confirms.
Run:
terraform apply tfplan.out
After apply completes:
terraform output and display all outputs.public_alb_dns as the app entry point.Final message: "Deployment complete. App URL: <public_alb_dns> Next: verify the full Validation Checklist in CLAUDE.md, then capture screenshots for your submission."