gvproxy: Disable port-forwarding on WSL

This commit disables ssh port forwarding on WSL by passing -1 to the -ssh-port flag of gvproxy. Port forwarding is not required on WSL and disabling it prevents port conflict with CRC.

Fixes: https://github.com/containers/podman/issues/20327

Signed-off-by: Gunjan Vyas <vyasgun20@gmail.com>
This commit is contained in:
Gunjan Vyas 2024-10-28 14:24:52 +05:30
parent 52caa0fbb9
commit 9cb80d1856
1 changed files with 1 additions and 1 deletions

View File

@ -32,7 +32,7 @@ fi
if [[ ! $ROUTE =~ default\ via ]]; then
exit 3
fi
nohup $GVFORWARDER -iface podman-usermode -stop-if-exist ignore -url "stdio:$GVPROXY?listen-stdio=accept" > /var/log/vm.log 2> /var/log/vm.err < /dev/null &
nohup $GVFORWARDER -iface podman-usermode -stop-if-exist ignore -url "stdio:$GVPROXY?listen-stdio=accept&ssh-port=-1" > /var/log/vm.log 2> /var/log/vm.err < /dev/null &
echo $! > $STATE/vm.pid
sleep 1
ps -eo args | grep -q -m1 ^$GVFORWARDER || exit 42