Terraform Cloud Agents on TFE
Terraform Cloud Agents allow Terraform Enterprise to communicate with isolated, private, or on-premises infrastructure. By deploying lightweight agents within a specific network segment, you can establish a simple connection between your environment and Terraform Enterprise which allows for provisioning operations and management.
Terraform Cloud Agents on TFE behave very similarly to Terraform Cloud Agents on TFC, with a few exceptions listed below.
Note: Terraform Cloud Agents on TFE are available in TFE releases v202109-1
and later.
Differences Between Agents on TFC and TFE
No restriction on Agent Count: Terraform Enterprise does not place a limitation on the number of Agents that can be registered per organization.
Hostname Registration: Terraform Cloud Agents registering with a TFE instance must define the TFE hostname via the
-address
CLI flag orTFC_ADDRESS
environment variable when runningtfc-agent
. By default,tfc-agent
will attempt to connect to Terraform Cloud, so this value must be explicitly defined when registering with a TFE instance.Custom Bundle Support: Terraform Cloud Agents on TFE support custom Terraform bundles. Custom bundles are created and defined within the TFE application; Agents will download the custom bundle based on the Terraform version information. See using a custom Terraform bundle for more detail on custom bundles in TFE.
Network Access Requirements: Terraform Cloud Agents on TFE must be able to communicate with the TFE instance via HTTPS. Additionally, the agent must also be able to communicate with any services required by the Terraform code it is executing. This includes the Terraform releases distribution service, releases.hashicorp.com, as well as the Terraform provider registry. Agents executing in a workspace that leverage a Terraform version that provides a custom Terraform bundle with pre-existing provider binaries do not need access to these resources.
Agent Version Compatibility: TFE places restrictions on what versions of Terraform Cloud Agents can be registered. This is to prevent an incompatible agent from registering with a TFE instance and attempting to execute a Terraform operation in an undefined way. Compatible versions of Terraform Cloud Agents on TFE will vary based on the specific TFE release sequence; any changes to compatible Terraform Cloud Agents versions will be noted in the Terraform Enterprise release notes.