Skip to content

Conversation

@RandomByte
Copy link
Member

@RandomByte RandomByte commented Dec 8, 2025

In some environments, 'localhost' might resolve to the IPv6 loopback
address '::1' which is often unexpected. This can especially lead to
problems where other tools might resolve 'localhost' differently in the
same environment.

This change explicitly binds to the IPv4 loopback address '127.0.0.1'
instead of resolving the address from 'localhost'.

In case remote connections are allowed, no host is specified so that
Node.js binds to either the unspecified IPv4 or -IPv6 address (which
usually also accepts IPv4 connections) [1]

[1] https://nodejs.org/docs/latest-v25.x/api/net.html#serverlistenport-host-backlog-callback

@RandomByte RandomByte requested a review from a team December 8, 2025 15:50
@RandomByte RandomByte force-pushed the fix/bind-to-v4-loopback branch from fc36a77 to 8a688bd Compare December 9, 2025 08:53
In some environments, 'localhost' might resolve to the IPv6 loopback
address '::1' which is often unexpected. This can especially lead to
problems where other tools might resolve 'localhost' differently in the
same environment.

This change explicitly binds to the IPv4 loopback address '127.0.0.1'
instead of resolving the address from 'localhost'.

In case remote connections are allowed, no host is specified so that
Node.js binds to either the unspecified IPv4 or -IPv6 address (which
usually also accepts IPv4 connections) [1]

[1] https://nodejs.org/docs/latest-v25.x/api/net.html#serverlistenport-host-backlog-callback
@RandomByte RandomByte force-pushed the fix/bind-to-v4-loopback branch from 8a688bd to 31b5018 Compare December 9, 2025 09:00
@maxreichmann
Copy link
Member

maxreichmann commented Dec 9, 2025

Unfortunately at least for me, while testing with Docker engine v28.3.0, this didn't fix the issue with ui5-test-runner not finding the local server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants