Skip to main content

CLI Configuration

OpenTofu CLI can be configured with some global settings, which are separate from any OpenTofu configuration and which apply across all working directories.

We've designed OpenTofu such that an average user running OpenTofu CLI interactively will not need to interact with any of these settings. As a result, most of the global settings relate to advanced or automated workflows, or unusual environmental conditions like running OpenTofu on an airgapped instance.

  • The CLI config file configures provider installation and security features.
  • Several environment variables can configure OpenTofu's inputs and outputs; this includes some alternate ways to provide information that is usually passed on the command line or read from the state of the shell.