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.

MediumSystem Design
29 practiced

Outline a CI/CD pipeline for Terraform: what runs when someone opens a PR, what needs a human approval before a production apply, and how non-production changes get applied automatically. Where would you keep the credentials it needs?

HardTechnical
22 practiced

A CloudFormation stack update partially succeeds, some resources get replaced, others just updated, and now the stack is in an inconsistent state that includes a stateful resource like a database. How do you reconcile that stack and get back to a known-good state without taking the database down?

EasyTechnical
19 practiced

Explain GitOps as a workflow for infrastructure changes: what does the branch, PR, review, merge, automated-apply flow actually look like, and what does having a reconciler constantly watching git buy you over people applying changes by hand?

HardSystem Design
24 practiced

Design a GitOps setup for infrastructure changes that has to work for 100+ teams. What would repo layout, merge controls, and environment promotion look like, and how do you recover if the control plane itself goes down?

HardSystem Design
20 practiced

Design the machine-image pipeline for a fleet of stateless instances behind a load balancer: how images get built and tested, how you promote an image across environments, and how you actually swap the fleet over to a new image with health checks and connection draining so nothing gets dropped. How would this change if you also needed to fast-track an urgent security patch?

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.