Terraform 1.5 Released: Import Blocks and Check Blocks
Terraform 1.5 introduced configuration-driven import blocks with config generation, check blocks for validating infrastructure, and new plantimestamp and strcontains functions.
Historical Archive. This article documents an event from 2023 and is preserved with its original date for reference. It is not current news, and details may have changed since publication.
What happened
Terraform 1.5 was released on June 12, 2023, according to the official Terraform CHANGELOG on GitHub. It was a feature-rich minor release that introduced two significant new configuration blocks, import and check, along with new functions.
Import blocks
Terraform 1.5 introduced import blocks, letting root-module authors declare their intent for Terraform to adopt an existing resource. Unlike the older terraform import CLI command, import became a configuration-driven, plannable action processed as part of a normal plan, so terraform plan shows a summary of resources to be imported alongside other changes. A companion -generate-config-out flag can generate HCL configuration for imported resources that lack it.
Check blocks
The release also added check blocks for validating infrastructure. Module and configuration authors can write independent check blocks with one or more assert blocks, each with a condition and error message, and can optionally load a scoped data source. Unlike precondition and postcondition blocks, a failing check does not halt execution, letting practitioners continually validate the state of their infrastructure outside the usual lifecycle.
New functions and enhancements
Terraform 1.5 added a plantimestamp function returning the timestamp at plan time, complementing the apply-time timestamp function, and a strcontains function to check whether a string contains a substring. It also improved resilience by periodically persisting state snapshots to the backend during apply and immediately on receiving an interrupt, reducing the window for lost data if Terraform is aborted.
Why it mattered
Terraform 1.5 modernised two important workflows. Configuration-driven import with config generation made adopting existing infrastructure far less error-prone, and check blocks gave teams a way to continuously assert the health of their infrastructure, both meaningful steps toward safer, more declarative infrastructure management.
Related on Skillo
See also: Terraform 1.0 and the compatibility promise, Terraform 1.9's cross-object validation.
Sources
Published date reflects the original event date (2023-06-12). This article is original Skillo editorial written from the sources above; facts were verified in September 2026.
Written by
Skillo Staff
0 Comments
Sign in to join the discussion.
No comments yet. Be the first to share your thoughts.