DevExpress / testcafe-hammerhead

A powerful web-proxy used as a core for the TestCafe testing framework. :hammer: :smiley:
https://testcafe.io
MIT License
171 stars 161 forks source link

Toggle IPv4 or IPv6 for proxy #2975

Closed aaldeed closed 10 months ago

aaldeed commented 10 months ago

What is your Scenario?

I would like to be able to use Testcafe when webpack is resolving localhost to an IPv6 address after moving to Node 18 from Node 16.

What are you suggesting?

Allow a command-line option and/or runner method to specify which protocol, IPv4 or IPv6 the hammerhead proxy will use. Right now _prepareDNSRouting in the proxy forces Node to use ipv4first but it doesn't seem to check IPv6 if no IPv4 address is found. With a new flag I'd like to be able to set using ipv4first or verbatim with the dns.setDefaultResultOrder calls.

What alternatives have you considered?

Right now my organization is forcing Webpack to use an IPv4 address to maintain compatibility with Testcafe after moving to Node 18. devServer: { ...baseConfig.devServer, host: '127.0.0.1' } This seems counterintuitive with Node 17+ prioritizing IPv6 now.

Additional context

No response

AlexKamaev commented 10 months ago

Thank you for sharing this information. We'll take it into account. However, we are not ready to implement this functionality since we are fully focused on other tasks. I'll close the issue for now. However, we can reopen this enhancement once we have more user requests.