Skip to content
This repository has been archived by the owner on Jul 4, 2023. It is now read-only.

Consul DNS not working on MacBook M1 #16

Open
cotjoey opened this issue Dec 15, 2022 · 3 comments
Open

Consul DNS not working on MacBook M1 #16

cotjoey opened this issue Dec 15, 2022 · 3 comments

Comments

@cotjoey
Copy link

cotjoey commented Dec 15, 2022

Hello,

I launched the Hashiqube vagrant (Docker provider) successfully on a MacBook Pro M1 after adding the Consul DNS to /etc/resolver/consul as per instructions here: https://github.com/servian/hashiqube#consul-dns.

However DNS resolution fails with a timeout when I run nslookup vault.service.consul 10.9.99.10. If I run nslookup vault.service.consul it tries to resolve from the local IP 192.168.2.1.

If I try the dig command with the DNS IP 10.9.99.10 and port 8600, it resolves fine.

Because of that problem I am unable to launch the Fabio LB URLs in my browser such as http://vault.service.consul:9999/.

After each change to /etc/resolver/consul, I restarted the following : sudo killall -HUP mDNSResponder

Thank you for any assistance you can provide.

@star3am
Copy link
Contributor

star3am commented Jan 11, 2023

Hi there @cotjoey - Thank you for opening this issue. I had some time to look into it and it seems that
config.vm.network "private_network", ip: "#{machine[:ip]}" is not working as expected with the docker provider.

A workaround is to use 127.0.0.1 for the DNS IP in /etc/resolver/consul

I will continue to look into this to find a fix.

Happy new year! Riaan

@pdomineaux
Copy link

pdomineaux commented Jan 12, 2023

Hello, same issue here with a M1 chip.
The trick with 127.0.0.1 instead of 10.9.99.10 in /etc/resolver/consul did not work for me.

I have noticed that on the M1 the gateway of the vagrant_network ( 10.9.99.1 ) is not reachable, but the same gateway is reachable on an Intel Mac.

@star3am
Copy link
Contributor

star3am commented Jan 12, 2023

@pdomineaux Good morning, thank you for your reply, yea you are correct, I could get DNS resolution working,

dig vault.service.consul @localhost -p 8600 +short
10.9.99.10

But 10.9.99.10 is not reachable, I'll dig a bit deeper and let you know if make any progress, have a good weekend!

Riaan

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants