Skip to main content
TERRAFORM-BASICS5 MIN READ

State Is Not a Cache

Explain Terraform state as the mapping Terraform uses to manage existing infrastructure.

Terraform state records the relationship between resource addresses and real infrastructure. Losing it is not like clearing a build cache; it can make Terraform believe unmanaged infrastructure needs to be created again. State can contain sensitive values and should be stored where access, durability, and locking match the environment's risk. Local state may be acceptable for a tutorial. Shared infrastructure needs a shared backend and locking. Visual modules: a three-part relationship diagram for configuration, state, and cloud objects; a sensitive-data warning callout; and a before-to-after backend move.

Read the full lesson

Sign up free — one personalized lesson every day, matched to your role and goals.

Already have an account? Sign in

← Back to library
Contact us