When attempting to ingress Terraform modules via Git over SSH a
Host key verification failed.
fatal: Could not read from remote repository. is displayed and the run fails.
This is a permissions issue with the SSH host key.
There are multiple causes and solutions for this issue.
Ensure there is no passphrase on the SSH key.
git clonethe repository via SSH with the same SSH key that Terraform Enterprise is using.
Ensure that the correct SSH key is attached to the correct Terraform Enterprise workspace. If there is no SSH key selected for the workspace then Terraform Enterprise will not save the SSH host key.
Verify that the SSH key configured on the workspace synchronizes with the SSH host key.
If you are using Single Sign-On (SSO), ensure that the SSH key has been configured for SSO operations on the VCS provider site.
If you continue to have experience this error during Terraform runs, please contact HashiCorp Support.