Closed describe19 closed 3 years ago
Hi, i can't finde the issue anymore but there was somebody in the past with the same setup and same problem. The problem ist that WSL 2 doesn't forward UDP ports by default. You have to forward the ports manually or connect to the real IP of your docker host.
What do you mean by 'connect to the real IP of your docker host'
I'm assuming in your case that Docker is running on WSL 2. WSL 2 is similar to a VM. This VM has a different IP address. To get the IP of my WSL VM i'm running wsl ip addr show eth0
wsl ip addr show eth0 5: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 link/ether 00:15:5d:2a:05:d8 brd ff:ff:ff:ff:ff:ff inet 172.30.207.85/20 brd 172.30.207.255 scope global eth0 valid_lft forever preferred_lft forever inet6 fe80::215:5dff:fe2a:5d8/64 scope link valid_lft forever preferred_lft forever
Maybe there is a different way to use Docker with WSL but that is the way that i know.
I heard that there are other solutions. For example UDP port forwards but this is only working with windows firewall as far as i know. (And might be not a solution for you because your firewall is turned off)
Okay yes, connecting to that WSL VM address works, now how do I do UDP port forwards with windows firewall? I thought it was only capable of allow/deny behaviour?
now how do I do UDP port forwards with windows firewall?
There are many users having issues with that and from what i remember there is no universal solution for that. Also the whole issue has nothing to do with this docker image. Also I'm not a WSL/WSL2 expert. I would recommend to give it a research from your own side.
All good thanks for your help
Sorry I'm asking for support, not an issue. I'm running this on docker on Windows and I can't connect to the server - I see it in 'browse local games' but whenever I try to connect I get the failed after 6 retries. I'm on Windows 10 using WSL 2 backend, disabled windows firewall.
I've tried in the garrys mod console to connect via 127.0.0.1, my local 192.168.1.x address and my public ip address, also by clicking on the server in the local browser - I get the same failed after 6 retries message every way.
docker-compose.yml:
server.cfg is empty
Container output:
Any ideas?