You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There's currently no way to connect to "localhost" or any other host names listed in the local /etc/hosts file. We could provide a hard-coded default for some common host names (like "localhost"), but this is bound to break.
In particular, this also affects usage with linked Docker containers where one container references another container by its host name. This means that there's currently no way to connect to other containers by their name.
Opening this ticket as a reminder - this actually depends on reactphp/dns#10
Isn't it possible to make the DNS dependency optional? I have a custom DNS server, and I don't want my application to be bound by its IP – this would mean headache for the maintainers of my code. :)
Ah. What I meant was, making that dependency optional will fix this issue, as well. If I either create a non-resolving connector or pass in a NullResolver, then things in /etc/hosts would be resolved with no problems, right?
If I either create a non-resolving connector or pass in a NullResolver, then things in /etc/hosts would be resolved with no problems, right?
Not quite :) #12 (and #7 and #46) only deal with making the DNS resolver optional. This means that NO DNS lookups whatsoever will be performed and as such only IPs can be used.
This ticket here discusses introducing a new feature to take the hosts file into account so that the host names listed there will actually be resolved. This should probably still be part of the DNS component, so this depends on reactphp/dns#10.
Activity
parhamdoustdar commentedon Jul 15, 2015
Isn't it possible to make the
DNSdependency optional? I have a custom DNS server, and I don't want my application to be bound by its IP – this would mean headache for the maintainers of my code. :)clue commentedon Jul 15, 2015
I agree with your suggestion, but it's probably unrelated to this ticket. Have you seen #12 yet? :)
parhamdoustdar commentedon Jul 15, 2015
Ah. What I meant was, making that dependency optional will fix this issue, as well. If I either create a non-resolving connector or pass in a
NullResolver, then things in/etc/hostswould be resolved with no problems, right?cboden commentedon Jul 15, 2015
Also see #7. If you want to finish that PR to have a
NullResolveras commented that could move this along.parhamdoustdar commentedon Jul 15, 2015
Thanks a lot. Will see if I can wrap my head around it and finish it :-)
clue commentedon Sep 7, 2015
Not quite :) #12 (and #7 and #46) only deal with making the DNS resolver optional. This means that NO DNS lookups whatsoever will be performed and as such only IPs can be used.
This ticket here discusses introducing a new feature to take the hosts file into account so that the host names listed there will actually be resolved. This should probably still be part of the DNS component, so this depends on reactphp/dns#10.
clue commentedon Apr 10, 2017
Closed in favor of reactphp/socket#88 (Migrating over to Socket now that #86 is in)