Terraform, OpenTofu and Terragrunt, from your laptop to your pull requests.

A version manager for your machine and CI, and a self-hosted server that plans and applies your infrastructure from pull requests.

CLI v6.3.0

tfv

Install, switch and manage several versions of Terraform, OpenTofu and Terragrunt. Upgrading tfv never removes the versions you installed.

  • Install, switch and remove versions without sudo; everything lives in ~/.tfv/
  • Switches automatically when you cd into a project, from .terraform-version, .tool-versions, terragrunt.hcl or required_version
  • Checks every Terraform and OpenTofu download against its published SHA256 checksums
  • Pin, upgrade, prune, exec and doctor commands, plus tab completion
  • Works the same on macOS, Linux and Windows, with mirror support for internal networks
  • 710 downloads / week
  • v6.3.0
npm install -g tfv

Server New · 0.1.0

tfv server

Pull request automation you host yourself. Every push gets a plan; every apply goes through the right people.

  • Finds the projects a pull request affects, with no config needed
  • Plans each one with the exact tool version it pins
  • Posts the plan with an Apply button; apply always uses the saved plan
  • Per-project permissions and approvers from your Git platform's users and teams
  • Policy checks, the two-person rule and an audit log
  • Drift checks that alert Slack, Teams, Discord, Google Chat or any webhook
docker run -p 8080:8080 -v tfv-data:/data \
  -e TFV_GITHUB_APP_ID=123456 \
  -e TFV_GITHUB_PRIVATE_KEY_FILE=/run/secrets/app.pem \
  -e TFV_GITHUB_WEBHOOK_SECRET_FILE=/run/secrets/webhook \
  -e TFV_REPO_ALLOWLIST='github.com/acme/*' \
  ghcr.io/marcdomain/tfv-server:0.1.0

tfv server

From pull request to apply

A plan comment on every push, Terraform commands from the PR, the apply report, and the dashboard with runs, metrics, resource usage and unlocking.

Source: charts/tfv-server/docs/flow.gif in the tfv repo

tfv CLI

Thirty seconds to the right version

Install a version, pin it for your team, and let the shell hook switch for you on every cd.

Read the CLI docs
npm install -g tfv

tfv install latest            # latest Terraform
tfv install latest -p tofu    # latest OpenTofu
tfv use 1.9.0
tfv pin                       # writes .terraform-version

eval "$(tfv shell-init zsh)"  # switch on cd

tfv server

Comment to run

Plan, apply and unlock from the pull request, or run Terraform commands like state list, import and output, each with its own permission.

All PR commands
tfv plan
tfv plan -p live/prod/app -t aws_instance.web
tfv plan -p live/prod/app --refresh-only
tfv apply -p live/prod/app
tfv state list -p live/prod/app
tfv unlock