Favicon of terraform

terraform

CLI tool that builds, changes, and versions infrastructure across cloud providers using execution plans and a resource dependency graph.

Terraform is a tool from HashiCorp for building, changing, and versioning infrastructure safely and efficiently through code. It manages resources across cloud providers, SaaS platforms, and custom in-house systems using a shared configuration language and a plugin-based provider system. It's built for platform engineers, DevOps teams, and anyone who needs to provision and change infrastructure repeatably instead of making changes by hand through a console, one click at a time, on systems that get more complex the longer they run unmanaged.

Key features

  • Infrastructure as code: infrastructure is described in a high-level configuration syntax, so a blueprint of a datacenter can be versioned, shared, and reused the same way application code is.
  • Execution plans: a planning step generates a preview of exactly what apply will do before anything changes, so there are no surprises when infrastructure gets modified.
  • Resource graph: Terraform builds a dependency graph of all resources and parallelizes the creation and modification of any resources that don't depend on each other, building infrastructure as efficiently as possible while exposing dependencies to the operator.
  • Change automation: complex changesets can be applied to infrastructure with minimal manual intervention, since the plan and graph together make the order of operations explicit ahead of time, cutting down on human error.
  • Plugin-based providers: providers for cloud and SaaS services are separate plugins that Terraform downloads automatically from the Terraform Registry; some are maintained by HashiCorp, others by other organizations and the community.

Ideal use cases

Terraform fits teams managing cloud infrastructure, compute, networking, storage, and related resources across one or more providers, who want proposed changes reviewed before they're applied. It's a natural choice for organizations that want infrastructure changes to go through version control and code review the same way application changes do, and for multi-cloud or hybrid setups where a single tool and configuration language can describe resources across different providers instead of learning a separate console for each one. It also suits teams that want a certification path for their infrastructure skills, since HashiCorp offers a Terraform Associate exam built around exactly this tool, with study materials on the same learning platform as the getting-started tutorials.

It's less useful for very small, single-resource setups managed by one person, where the overhead of state files and a plan and apply workflow may outweigh the benefit. It's also worth noting that this particular repository contains Terraform core only, the CLI and the graph engine; the providers that actually talk to specific cloud services are separate plugins maintained elsewhere and published through the Terraform Registry, so evaluating Terraform for a specific platform also means checking whether a maintained provider exists for it.

Installation

The README doesn't include install commands directly; it points to the Terraform website for getting started guides and to the contributing guide for building from source. For using Terraform day to day, install a released binary rather than building from this source repository. A common approach on macOS:

brew tap hashicorp/tap
brew install hashicorp/tap/terraform

Then confirm it installed:

terraform -version

From there, the documentation and the Getting Started guides on HashiCorp's learning platform walk through writing a first configuration file, running a plan, and applying it against a real provider.

To build Terraform core from this source repository instead, for contributing to the project itself, follow the compiling instructions in the contributing guide linked from the README. That guide also covers how bug reports are triaged, per the separate bug triage guide referenced in the README, and how to contribute to the documentation, which now lives in a separate web-unified-docs repository rather than in this one.

Tags:

Frequently asked questions

Share:

Stars
48.9K
Forks
10.4K
Last commit
3 hours ago
Repository age
12 years
Self-hosted
No
Activity score
87/100
View Repository
Built with:

Similar to terraform

Favicon

 

  
  
Favicon

 

  
  
Favicon