Skip to content

WSL 2.0.6 mirrored network - can not connect to Docker container ports from Windows host #10683

Description

Windows Version

10.0.22621.2500

WSL Version

2.0.6.0

Are you using WSL 1 or WSL 2?

  • WSL 2
  • WSL 1

Kernel Version

5.15.133.1-1

Distro Version

Ubuntu 22.04

Other Software

No response

Repro Steps

  • Configure WSL to use the mirrored networking mode.
  • Open a port in a Docker container.
  • Connect to this port using localhost:port from the host Windows system.

Expected Behavior

Connected successfully.

Actual Behavior

Chrome error:

This site can’t be reached
localhost refused to connect.

Diagnostic Logs

Configuration:

[wsl2]
autoMemoryReclaim=gradual
networkingMode=mirrored
dnsTunneling=true
autoProxy=true

Reconfiguration to the NAT mode solves the issue.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions