cycloidio / terracognita

Reads from existing public and private cloud providers (reverse Terraform) and generates your infrastructure as code on Terraform configuration
MIT License
2.2k stars 164 forks source link

OpenTofu support #397

Open skyzyx opened 1 year ago

skyzyx commented 1 year ago

https://opentf.org/announcement

We want to understand how this project is affected by the OpenTF announcement, and what the plans for support are moving forward.

From a technical perspective, I expect that it will be a no-op for the time being as OpenTF anticipates maintaining compat/interop for the foreseeable future. (However, OpenTF has stated that some functionality may be added to OpenTF that is a superset of what's in base Terraform. [source])

From a process perspective:

  1. If there is a bug in OpenTF that does not exist in Terraform (or vice-versa), will bug reports (as they pertain to this project) be treated equally on both platforms?

  2. Will testing be performed with code targeting both platforms?

  3. For OpenTF's potential future "superset" functionality, will that be treated as a first-class citizen? (Most members of the Terraform ecosystem are planning to take this on a case-by-case basis, which is perfectly reasonable.)

xescugc commented 1 year ago

The plans are to move to OpenTF as Hashicorp is still keeping the new license.

The use this lib has of Terraform is really unconventional, we are importing it as a lib, which is against the Hashicorp recommendations and to further it more they moved all the code to internal/ so no one can actually do what we are doing.

For this reason we have a fork of Terraform with the changes we need for it to be able to be imported, the changes are automated in a script:

I guess we'll have to do the same with OpenTF.

So to answer the questions:

If there is a bug in OpenTF that does not exist in Terraform (or vice-versa), will bug reports (as they pertain to this project) be treated equally on both platforms?

Yes, we'll support OpenTF as we will also use it

Will testing be performed with code targeting both platforms?

Would be nice to add but it'll not be that easy as it requires changes to the codebase to run it in different libraries, as we do not run TF as a binary but import it as a lib.

For OpenTF's potential future "superset" functionality, will that be treated as a first-class citizen? (Most members of the Terraform ecosystem are planning to take this on a case-by-case basis, which is perfectly reasonable.)

We'll handle it case by case.

We also have other projects that are importing Terraform that we'll move to OpenTF eventually: