Core functions with identical implementations for Terraform, OpenTofu, Terratest, and other software in the so-called Terra/Fu ecosystem.
While some of these can be implemented in HCL, some of them begin to push up against the limits of Terraform and the HCL2 configuration language. Exposing these functions as both a Go library as well as a Terraform/OpenTofu provider enables us to use the same functionality in both our Terraform/OpenTofu applies as well as while using a testing framework.
The goal of this provider is not to call any network APIs, but to provide pre-built functions in the form of Data Sources or Provider Functions.
View the list of issues, and give a thumbs-up to the ones you'd like to see. This is how we prioritize the work.
- We have automated testing that runs on every commit and every pull request.
- We intend for the Go libraries to work with all non-EOL versions of Go (i.e., current, current-1).
- Built using the Terraform Plugin Framework, which speaks Terraform Protocol v6.
Testing type | Details | Description |
---|---|---|
integration | Terraform 1.0–1.11 | Executes the provider with this release, pulling from registry.terraform.io . |
integration | OpenTofu 1.6–1.9 | Executes the provider with this release, pulling from registry.opentofu.org . |
unit | Go 1.23–1.24 | Tests using these versions. |
mutation | Go 1.23–1.24 | Tests using these versions. |
fuzz | Go 1.23–1.24 | Tests using these versions. |
terratest | Go 1.23–1.24 | Tests using these versions. |
See the docs/
directory for user-facing documentation.
If you are using this as a Go library, see the documentation at pkg.go.dev.
After the provider is installed, you can run terraform-provider-corefunc
on the CLI.
- Install with either
terraform init
ormake build
. - The Go binary path (discovered by running
./find-go-bin.sh
) is on your$PATH
.
This will display the following text:
terraform-provider-corefunc
This binary is a plugin. These are not meant to be executed directly.
Please execute the program that consumes these plugins, which will
load any plugins automatically
However, by passing the --help
flag, you can see the other options available, including a description of the software.
terraform-provider-corefunc --help
The provider has one primary sub-command: version
. It includes long-form version information, including the build commit hash, build date, Go version, and external dependencies.
terraform-provider-corefunc version