Introduction
Problem
You have configured Terraform Enterprise to use a secondary hostname as described in the official documentation found here
Your parameters look something like the following
TFE_HOSTNAME: "tfe56.example.com"
TFE_HOSTNAME_SECONDARY: "tfe56-secondary.example.com"
TFE_OIDC_HOSTNAME_CHOICE: secondary
TFE_VCS_HOSTNAME_CHOICE: secondary
TFE_SAML_HOSTNAME_CHOICE: secondary
TFE_RUN_TASK_HOSTNAME_CHOICE: secondary
You configure a VCS connection for this secondary hostname as documented here. At the final step of confirmation you get an error page as below.
Prerequisites
- Terraform Enterprise >= v202504-1
Cause
You logged into Terraform Enterprise and created the VCS while connect to the TFE_HOSTNAME
address.
Solutions:
You must be logged into Terraform Enterprise and create the VCS while connected to the TFE_HOSTNAME_SECONDARY
The official documentation points this out here
When the VCS integration uses the secondary hostname, you should continue using it while setting up the new VCS connection.
Outcome
While logged intoTFE_HOSTNAME_SECONDARY
you will be able to successfully create the VCS connection
Additional Information
-
Official documentation can be found here