Skip to content

Where credentials are read

Turf™ runs in two processes, and each reads its own environment. Put a credential where the process that uses it can see it.

  • Providers run in the engine. They read the engine’s environment, and of your shell’s or your agent’s only the variables you name for them. An engine the server started has a small fixed environment.
  • Variables, the state backend and state encryption are handled by the MCP server. They read the server’s environment and the values your agent passes to open and each plan command.
  • Provider arguments in the configuration (profile, assume_role, config_path) override the environment a provider would otherwise read.

A variable you export in a terminal reaches the server only when you start your agent, or the Turf CLI, from that terminal. An engine the server started takes only Turf’s own settings from the server’s environment, your MCP client’s env block included: TURF_*, DO_NOT_TRACK, CI, TF_PLUGIN_CACHE_DIR and TF_CLI_CONFIG_FILE. Nothing else reaches the engine’s own environment, and the Homebrew service reads none of it.

A variable a provider needs travels another way. Name it in TURF_PROVIDER_ENV, in the same env block, and the server sends it with each run to the engine, however the engine was started: see Send a variable to providers. Credentials in their usual files, such as the default AWS profile and ~/.kube/config, need nothing set.

your shellyou start your agent, or the Turf CLI, from itstartsMCP serverturf-mcp-serverENVIRONMENTREADS HEREHANDLESwhat your agent was started with,plus the env block of its MCP configTF_VAR_*, backend credentials, TF_TOKEN_*,TF_ENCRYPTION, ~/.tofurcvariables, the state backend, state encryption,init's installsplans and applies: variable values travel, and the variables it names for providers;the rest of the server's environment staysengineturf-engineENVIRONMENTRUNS HEREits own: a small fixed one, or the turfservice's (launchd, turf.env); then thevariables the server named for providers;then the configuration's mise environmentthe providers, which read it,and ~/.aws/config, ~/.kube/config
Two environments. The server reads yours; the providers read the engine's, with the variables you name for them.

A TF_VAR_ value reaches a provider only through a variable its block references. TF_ENCRYPTION never leaves the server.

What Read by From
Providers (AWS, Azure, Google Cloud, Kubernetes®, …) the engine the engine’s own environment, then the variables the server sends by name (the provider environment), then the configuration directory’s mise environment, each over the one before
Variables, the state backend, state encryption the MCP server the tool calls (open’s values, kept for the workspace, under each plan command’s own) and the server’s environment, set in your MCP client’s env block; never mise
Provider arguments in HCL (profile, assume_role, config_path) the configuration override all three: the way to pin an account in the configuration itself; a secret there arrives through a variable, never a literal

Turf™ is a trademark of Turf LLC. Terraform® is a trademark of HashiCorp. Ansible® is a trademark of Red Hat, LLC, registered in the United States and other countries. Helm®, Kubernetes®, Prometheus® and OpenTelemetry® are registered trademarks, and Jaeger™ is a trademark, of the Linux Foundation. OpenTofu® and Model Context Protocol® are registered trademarks of LF Projects, LLC. All other trademarks are the property of their respective owners. Turf is not affiliated with, endorsed by, or sponsored by HashiCorp, IBM, Red Hat, the Linux Foundation, LF Projects or the OpenTofu project.

© 2026 Turf LLC. Free for individuals, education and small businesses within the Community limits, under the Turf Community Edition License 1.0. Government and larger organizations need a commerciallicense.turf.build · Discord ·GitHub