Cannot access robot interface from Docker running on Windows

Note: in case this is me doing something wrong or this is not the correct category, let me know.

Steps to reproduce:

  1. Dowload the new lastest Docker image from Universal Robots in DockHub.
  2. Run the specified commands to launch URSim.
docker pull universalrobots/ursim_e-series
docker run --rm -it universalrobots/ursim_e-series
# other options for launching:
docker run --rm -it -p 5900:5900 -p 6080:6080 universalrobots/ursim_e-series
docker run --rm -it -e ROBOT_MODEL=UR3 universalrobots/ursim_e-series
# etc...

Expected Behavior:

This is from a VM Ubuntu 22.04 LTS. The UI can be accessed whether the image is launched from the terminal or VS Code.

Actual Behavior:

On Windows the image can be launch from either Docker Desktop or Ubuntu 22.04 WSL, but it won’t display it. Same result when launching the image from VS Code or Docker Desktop:

The Ubuntu subsystem is enabled in Docker Desktop with WSL 2:

Workaround Suggestion:

Apparently Windows cannot access private IP addresses in a Linux Subsystem, so I tried to launch it from a reachable IP address, but didn’t work out.
So my subsystem has the IP and Windows can ping to it.

But URSim cannot be binded to it. Also tried different ports, but all failed.

$ docker run --rm -it -p -p 6080:6080 universalrobots/ursim_e-series
docker: Error response from daemon: Ports are not available: exposing port TCP -> listen tcp can't bind on the specified endpoint.ERRO[0000] error waiting for container: context canceled

$ docker run --rm -it -p -p 6080:90001 universalrobot
docker: Invalid containerPort: 90000.
See 'docker run --help'.

$ docker run --rm -it -p -p 50002:6080 universalrobot
docker: Error response from daemon: Ports are not available: exposing port TCP -> listen tcp can't bind on the specified endpoint.
ERRO[0000] error waiting for container: context canceled
  • What other IP addres(es) or ports can be used?
  • Anybody has been able to launch the interface from Windows WSL?

Affected Version(s):

URSim for e-Series 5.13

The console prompt is incorrect.

Run these two commands on your Windows host machine.

docker network create --subnet= ursim_net
docker run -it -e ROBOT_MODEL=UR3e --net ursim_net --ip -p 30002:30002 -p 30004:30004 -p 6080:6080 --name ur3e_container universalrobots/ursim_e-series

Afterwards, open Google Chrome and navigate to .

I’ve also been able to access PolyScope via a container launched inside WSL2. For that, open a console in Windows and run ipconfig then look for your virtual ethernet adapter (WSL) IPv4.
Afterwards, in Chrome, go to http://:6080/vnc_auto.html .

Yeah, that did the trick, thanks a lot! :smiley: