When using Playwright MCP tools to navigate to the dev server, localhost:4000 results in net::ERR_CONNECTION_REFUSED but 0.0.0.0:4000 works.
This is likely a Docker networking or binding issue - the dev server binds to 0.0.0.0 but localhost resolution inside the container may not route correctly.
Workaround: Use 0.0.0.0:4000 instead of localhost:4000 for Playwright navigation.
To investigate:
- Check webpack-dev-server host binding configuration
- Verify /etc/hosts or DNS resolution inside container
- May be related to IPv4 vs IPv6 localhost resolution
When using Playwright MCP tools to navigate to the dev server,
localhost:4000results innet::ERR_CONNECTION_REFUSEDbut0.0.0.0:4000works.This is likely a Docker networking or binding issue - the dev server binds to 0.0.0.0 but localhost resolution inside the container may not route correctly.
Workaround: Use
0.0.0.0:4000instead oflocalhost:4000for Playwright navigation.To investigate: