InterviewStack.io LogoInterviewStack.io

Infrastructure as Code and Automation Questions

Defining, provisioning, and automating infrastructure programmatically. Covers declarative IaC with Terraform and comparable tools like CloudFormation (resource and provider model, state management and remote backends, module design and reuse, workspaces, drift detection, and safe plan/apply workflows), plus the broader automation discipline: provisioning pipelines, golden-image and machine-image building, scripting glue, self-service platforms, and end-to-end environment stand-up. The authoring, lifecycle, and automation of infrastructure code that reduces manual toil across provisioning workflows.

EasyTechnical
20 practiced

What's the difference between using Terraform workspaces versus separate directories or separate state backends per environment? What tends to go wrong with each, and when would you recommend one over the other?

EasyTechnical
21 practiced

What does terraform import actually do, and can you think of a time you'd reach for it instead of just writing a fresh resource block?

HardSystem Design
21 practiced

Design a drift-detection and remediation system for thousands of cloud resources spread across multiple accounts and regions. How would it decide what to auto-fix versus what needs a human to sign off, and how do you keep the whole thing auditable?

MediumTechnical
16 practiced

Walk me through blue-green versus canary deployment from an infrastructure perspective; when would you reach for each? Think about traffic routing, resource duplication, cost, and what gets harder when a database schema change is part of the rollout.

EasyTechnical
30 practiced

What is Terraform state, and why does Terraform need to keep track of it at all? What would actually break if it didn't exist?

Unlock Full Question Bank

Get access to all Infrastructure as Code and Automation interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.