Closed kevinclark closed 3 years ago
Just found this issue which suggests it's a known issue. Seems very strange that consul would say "the resolver is the way to go" and then the hashistack would explicitly not use that supported method.
Hi @kevinclark - thanks for pointing this out, and for highlighting the gap between the two tools. Our intent, of course, is for these tools to work well together. I think that this is effectively a specific case of https://github.com/hashicorp/terraform/issues/3536 which is a long-standing issue. I'm going to close this issue as a duplicate of that, unless you strongly object, because the technical fix on our end is exactly the same.
I really appreciate you pointing this out from this new perspective. I've reached out to our internal release engineering team to highlight the fact that there is a cross-product issue with a probably-similar solution (cgo-enabled builds) and see when they can fit it in to their roadmap.
Please feel free to reach out (ddreier@hashicorp.com) if you feel strongly this shouldn't be closed as a duplicate - I'm happy to talk.
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
The context here is that I've setup a consul cluster in our datacenter and added a dns resolver to my local mac at /etc/resolver:
While system services all use the resolver just fine, terraform doesn't. The problem appears similar to this docker issue. This is particularly problematic as I'm using the Hashicorp-prescribed way to setup local dns resolution on a mac.
Terraform Version
Terraform Configuration Files
Debug Output
Expected Behavior
My consul agent (defined in /etc/resolver/consul) should have been used to resolve consul.service.consul, rather than going through my standard DNS servers.
Actual Behavior
The resolver was ignored.
Steps to Reproduce
terraform init
Additional Context
Context is largely up top. I'm also on a VPN to get to my cluster, but that doesn't appear to effect the system resolution. The VPN also explicitly doesn't capture all traffic or rewrite DNS, so I believe it to be a moot point.
References
Docker seemed to have a similiar issue here.