Failing to access localhost on macOS
philippseith opened this issue · 1 comments
philippseith commented
I am trying to build a simple reverse proxy with https://hexdocs.pm/reverse_proxy_plug and its https://github.com/edgurgel/httpoison http client plugin. When I forward requests to a (angular dev-). server, listening on localhost:4200, they finally reach :hackney.request/5 with the url "http://localhost:4200" which times out, I guess because localhost resolves on macOS to ::1 instead of 127.0.0.1 (which seems to be the resolution result in hackney).
When the angular dev server is explicitly started with address 127.0.0.1, the request works.
used versions:
OTP 25
Elixir 1.14.1
hackney 1.18.1