liveBook · Manning

Drift

As explained in Bootstrapping Microservices, Second Edition: With Docker, Kubernetes, GitHub Actions, and Terraform

Configuration drift is the divergence between the recorded or declared configuration of infrastructure and its actual state.

Configuration drift is the difference between declared or recorded infrastructure and its actual live state. Terraform detects it by loading configuration and state, then refreshing known resources from the live environment. section 7.8.7

Terraform manages drift through three related comparisons:

  • It treats resources as owned when they appear in infrastructure code or the state file. section 7.8.7
  • It refreshes recorded resources from live infrastructure, including changes made manually. section 7.8.7
  • It compares refreshed state with configuration and determines the changes required to reconcile infrastructure. section 7.8.7

How Bootstrapping Microservices, Second Edition: With Docker, Kubernetes, GitHub Actions, and Terraform covers it

How deep it goes
Explains ownership, state refresh, and reconciliation while stopping short of a detailed remediation workflow.
Examples
Uses manually tweaked infrastructure and an Azure resource group recorded in terraform.tfstate as concrete examples.
What it assumes
Assumes Terraform configuration, state files, and managed infrastructure, while clarifying their ownership relationship.
What you can do after
Diagnose drift by inspecting Terraform state and understanding how refresh compares live resources with declared configuration.
How it connects
Connects configuration drift with Terraform state, infrastructure as code, live infrastructure, and manual changes.

Also explained in

Compare how 12 books explain drift →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Bootstrapping Microservices, Second Edition: With Docker, Kubernetes, GitHub Actions, and Terraform. The section links point to the parts of the book it draws on.