SpinTheMic
Pro

Interview practice question

Creating the backend for Terraform state

Cloud & DevOps · Terraform and IaC · Intermediate

You need an S3 bucket to store Terraform state, but you want to create that bucket with Terraform too. How do you solve this chicken-and-egg problem?

What a strong answer covers

Your AI report card counts how many of these ideas you cover.

  • Bootstrap config with local state creates bucket.
  • Then migrate its state into the bucket.
  • Or create via separate small stack/CloudFormation.
  • Enable versioning, encryption, locking.
  • Protect with prevent_destroy.
Practise this topic

Start without signing up. Sign in free to get an AI report card on your answer.

See all topics