microsoft / microsoft/WSL

Ports are not forwarded using podman 6

Open
#41,204 12 comments 9 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

interop network wsl2
Dominant language
C++
Stars
33.7k
Forks
1.8k
Avg merge
3d 17h
Merged PRs (30d)
116

Description

### Windows Version

Microsoft Windows [Version 10.0.26200.8875]

### WSL Version

2.7.11.0

### Are you using WSL 1 or WSL 2?

- [x] WSL 2
- [ ] WSL 1

### Kernel Version

6.18.33.2-microsoft-standard-WSL2

### Distro Version

Manjaro

### Other Software

podman version 6.0.1

### Repro Steps

Run in WSL2:

```shell
sudo podman run -it --rm -p 8081:80 docker.io/nginx
curl http://localhost:8081
```

### Expected Behavior

The curl command (in WSL2) succeeds and in the browser on windows you can open http://localhost:8081.

### Actual Behavior

The curl commands (in WSL2) succeeds but in the browser you **cannot open** http://localhost:8081 but get ERR_CONNECTION_REFUSED.

The problem occurs only with podman 6. Podman 4.x and 5.x work fine. I have installed podman in Manjaro with `sudo pacman -S podman`.

### Diagnostic Logs

_No response_

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the WSL2 case with `sudo podman run -it --rm -p 8081:80 docker.io/nginx`, then compare localhost forwarding with Podman 4.x or 5.x and 6.0.1. Investigate the WSL2-to-Windows port path; done means `curl http://localhost:8081` still succeeds and Windows can open the same URL.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux
Domain
networking, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.