The open source infrastructure as code tool.
Previously named OpenTF, OpenTofu is a fork of Terraform that is open-source, community-driven, and managed by the Linux Foundation.
Our Goals
Truly open-source
under a well-known and widely-accepted license that companies can trust, that won’t suddenly change in the future, and isn’t subject to the whims of a single vendor.
Community-driven
so that the community governs the project for the community, where pull requests are regularly reviewed and accepted on their merit.
Impartial
so that valuable features and fixes are accepted based on their value to the community, regardless of their impact on any particular vendor.
Layered and modular
with a programmer-friendly project structure to encourage building on top, enabling a new vibrant ecosystem of tools and integrations.
Backwards-compatible
so that the existing code can drive value for years to come.
How to contribute to OpenTofu?
The best way to show practical support for the OpenTofu initiative is to contribute. This contribution guide explains OpenTofu contribution recommended practices, including how to submit issues, how to get involved in the discussion, how to work on the code, and how to contribute code changes.
ContributeFrequently Asked Questions
What is OpenTofu?
OpenTofu is a Terraform fork, created as an initiative of Gruntwork, Spacelift, Harness, Env0, Scalr, and others, in response to HashiCorp’s switch from an open-source license to the BUSL. The initiative has many supporters, all of whom are listed here.
Why was OpenTofu created?
The BUSL and the additional use grant outlined by the HashiCorp team are ambiguous, which makes it challenging for companies, vendors, and developers using Terraform to decide whether their actions could be interpreted as being outside the permitted scope of use.
Hashicorp’s FAQs give some peace of mind to end users and system integrators for now, but the licensing terms’ implications for future usage are unclear. The possibility that the company’s definition of “competitive” or “embedding” could change or the license could be further modified to make it closed source prompts uncertainty for Terraform users.
We firmly believe that Terraform should remain open-source because it is a project many companies use, and many contributors have made Terraform what it is today. Terraform’s success would not have been possible without the community’s work to build many supporting projects around it.
What are the differences between OpenTofu and Terraform?
There will be no differences between Terraform (1.5.x versions) and OpenTofu. As new versions are released, this will change.
Why should you use OpenTofu instead of Terraform?
Personal use
Initial impressions suggest you could use either OpenTofu or Terraform for personal use, as the BUSL license has no restrictions for non-commercial use cases. That may change as the Terraform ecosystem becomes increasingly unstable, and a switch to another license may happen. Those familiar with Terraform will have no issues adopting OpenTofu for personal use, so there will be no knowledge gaps, at least at the start.
Consultants
A consultant should offer their clients the best possible solution that aligns with their budget. OpenTofu will be on par with Terraform, and one of the project’s central objectives is to listen to the community’s issues, so it makes sense to recommend a project that will always stay open-source. Anyone who has used Terraform in the last eight years has probably come across issues that took some time to be resolved. The large community involved in developing OpenTofu means this will no longer be the case.
Companies
Companies will encounter more difficulties with the situation. Switching to a new project carries risks, but staying with a project that changes its license without warning is far riskier. This risk is minimized by giving OpenTofu to the Linux Foundation, and OpenTofu’s aim of maintaining feature parity with Terraform for future releases reduces the technical risks.
Will OpenTofu be compatible with future Terraform releases?
The community will decide what features OpenTofu will have. Some long-awaited Terraform features will be publicly available soon.
Some companies have pledged to pay for full-time engineers to work on OpenTofu. We have 19 such engineers involved already — and many other individuals, companies, projects, and foundations are prepared to contribute.
Can I use OpenTofu as a drop-in replacement for Terraform? Is OpenTofu suitable for production use?
Initially, OpenTofu will be a drop-in replacement for Terraform, as it will be compatible with Terraform versions 1.5.x. You won’t need to make any changes to your code to ensure compatibility. OpenTofu is suitable for production use cases without any exception.
Supporters
- Supporting Companies: 158158
- Supporting Projects: 1111
- Supporting Foundations: 11
- Supporting Individuals: 781781
How to support OpenTofu in pledging?
Pledging to the OpenTofu manifesto can be done by:
1. Going to the manifesto repository.
2. Forking the repository.
3. Adding your pledge in the index.html file.
4. Pushing the changes to your forked repo, and create a PR.
5. Starring the repository.
6. Joining our Slack community & following us on Twitter.
Latest News
OpenTofu Release Candidate Is Out, GA Set for Jan 10th
OpenTofu v1.6.0-rc1, the final stage before the first stable release, is out today. It follows the quick succession of its alpha and beta versions, on the road to an expected General Availability release on January 10, 2024, right after the holidays.
This release includes bug fixes, stability improvements, and updates to documentation. Importantly, this version highlights the stability of our new public registry, which debuted with the v1.6.0-beta1 release three weeks ago, and has been extensively tested by us and the early adopters from the OpenTofu community.
From Idea to Release Candidate in 4 Months
The OpenTofu journey has been a whirlwind, spanning from a proposition to a release candidate in just four months.
This is a major milestone for us, but also a bittersweet moment. Looking back on the beginning of our journey, there was hope that HashiCorp would hear our appeal, reverse its decision and restore balance to the ecosystem.
Yet, here we are … and everything that transpired after those initial weeks of surprise, hope, and disappointment can only be characterized as a case study of collaboration. Peers, community, and competitors all united to work together to preserve an open-source option for Infrastructure-as-Code.
To recap, here are the major milestones so far:
As of December 18th, OpenTofu had surpassed 31,000 downloads, had 60 committers, and had seen over 1,000 pull requests and issues. The project’s main repository has also amassed over 16,450 GitHub stars on top of the 36,200+ GitHub stars for the manifesto.
Now, with that out of the way, let’s talk shop.
The Registry Challenge
From the moment the OpenTF fork was announced, it was evident that a new public registry would be needed—an open-source substitute for the Terraform one, which is no longer accessible for non-Terraform projects following the TOS changes.
Similar to its predecessor in function, this new registry would have to be a highly available package resolution service for all providers and modules used by OpenTofu. Additionally, it had to meet other specific criteria, including:
- The registry had to be as self-sufficient as possible and require as little maintenance as possible.
- Anticipating increasing demand, it needed to be built for high availability and perform well at scale.
- It should smoothly transition from HashiCorp's registry, following the 'drop-in replacement' approach.
- Whatever we went with, it had to be open-source.
Brewing Together
Homebrew is the de facto standard package manager on macOS – just as APK or RPM is to Linux or Chocolatey/Winget is to Windows. Its simple nature, open-source package database at its core, and efficiency for packaging applications inspired something similar that would be ideal for our needs, while its popularity served as evidence of its scalability.
As we were discussing this, Homebrew lead Mike McQuaid, who has been working on that project for more than 14 years, took notice of our conversation and joined the fray, contributing helpful insights about the repository structure:
For me, this experience highlighted the importance of the Open Source concept and reminded me that without its inherently collaborative nature, engagements like that would be few and far between.
This instinctive and uninhibited camaraderie is what Open Source is all about.
Implementation
Amongst other things, Mike’s advice for us was to fragment the repo, to improve performance:
“We went through a ‘sharding’ process recently so that we have formulae/casks in our largest repositories split into subdirectories…The ‘git’ performance is dramatically better in this format.”
Following up on it, we built the registry (https://registry.opentofu.org) as a collection of alphabetized subdirectories broken down by namespace. These were hydrated with information from all providers and modules currently available on GitHub, each with its own JSON file with metadata and other specifics.
Importantly, using static files and hosting them on a Cloudflare R2 public bucket also lets us take full advantage of its CDN capabilities, ensuring performance and high availability with over 94% cache hit rates (on that note, huge THANKS to CloudFlare for sponsoring this project!).
Outside of our own tests, the four most requested files were:
/.well-known/terraform.json
/v1/providers/hashicorp/null/versions
/v1/providers/hashicorp/template/versions
/v1/providers/hashicorp/aws/versions
With the registry live, we set up a GitHub Action to scan for updates to indexed resources. We also introduced an IssueOps process for adding new providers. With it in place, new submissions would be auto-processed and auto-validated when they go into the registry, with Issues providing context and transparency.
We’re currently exploring a dedicated UI for package and documentation browsing.
Next Stop: Jan 10th
With the holidays in full swing, we decided to roll out a release candidate first and schedule the GA for January 10th. Meanwhile, you can already start testing OpenTofu by simply following the directions provided here. It is a drop-in replacement so Terraform users will feel right at home, which is the whole idea.
If you are interested in contributing to the project, please check out these contribution guidelines, and don’t forget to join our Slack community.
Happy holidays!
P.S.
While concluding the work on this post, and the upcoming release, we learned that Mitchell Hashimoto, HashiCorp’s legendary co-founder, announced that he will leave the company after 11 years.
Mitchell’s work on projects such as Vagrant, Consul, Vault, and of course Terraform is a source of inspiration for us and many others within the Open Source community.
The entire OpenTofu team extends its heartfelt gratitude to Mitchell for all of his numerous contributions, as we eagerly anticipate learning about the next steps in his already remarkable journey.