tezvyn:

State drift in Terraform

Source: interviewintermediate

WHAT IT TESTS: IaC state versus reality. OUTLINE: drift is when live infrastructure diverges from recorded state, usually via manual console changes; detect with plan or refresh, remediate by re-applying or importing. RED FLAG: hand-editing state.

WHAT IT TESTS: whether you understand how IaC tracks reality and how it desynchronizes. ANSWER OUTLINE: state drift is when actual cloud resources differ from what the IaC state file records, typically because someone changed a resource manually out of band. Detect it by running plan or refresh, which compares live infrastructure against state and config and shows the diff. Remediate by re-applying to converge reality back to desired state, or by importing or updating config if the change should stay. RED FLAG: hand-editing state files.

Read the original → interview

Get five bites like this every day.

Tezvyn delivers a daily feed of 60-second tech bites with quizzes to lock in what you learn.

State drift in Terraform · Tezvyn