netbrain / zwift

Easily zwift on linux
The Unlicense
286 stars 32 forks source link

[HELP] Can not run swifter after install "The path /tmp/.X11-unix is not shared from the host and is not known to Docker." #71

Closed FlorMaye closed 9 months ago

FlorMaye commented 9 months ago

Container information Docker version 25.0.2, build 29cf629

Issue details

i.e Having issues with launching zwift, tried running the gl example (https://github.com/netbrain/zwift/issues/54#issuecomment-1877155180)

Command response after "install" and try to run with "zwift" command

What's Next?

  1. Sign in to your Docker account → docker login
  2. View a summary of image vulnerabilities and recommendations → docker scout quickview docker.io/netbrain/zwift:latest
    • [[ -f /proc/driver/nvidia/version ]]
    • VGA_DEVICE_FLAG='--gpus all' +++ '[' docker = podman ']' ++ docker run -d --rm --privileged -e DISPLAY=:1 -v /tmp/.X11-unix:/tmp/.X11-unix -v /run/user/1000/pulse:/run/user/1000/pulse -v zwift-florian:/home/user/Zwift --gpus all docker.io/netbrain/zwift:latest docker: Error response from daemon: Mounts denied: The path /tmp/.X11-unix is not shared from the host and is not known to Docker. You can configure shared paths from Docker -> Preferences... -> Resources -> File Sharing. See https://docs.docker.com/ for more info. Preferences
netbrain commented 9 months ago

The path /tmp/.X11-unix is not shared from the host and is not known to Docker. You can configure shared paths from Docker -> Preferences... -> Resources -> File Sharing. See https://docs.docker.com/ for more info. Preferences

What system are you on? Windows? Or is this the docker desktop equivalent in Linux?

FlorMaye commented 9 months ago

Distributor ID: Ubuntu Description: Ubuntu 22.04.3 LTS Release: 22.04 Codename: jammy

I tryed to install docker without the desctop application but somehow nothing worked and then I installed the Linux docker desctop applicatioin.

I am new to linux an docker so I need to work through a lot of stuff at the moment

netbrain commented 9 months ago

I would personally recommend using docker without desktop. You could also try giving podman a spin.

FlorMaye commented 9 months ago

Thanks for your recommendation. I uninstalled docker and docker-desktop completely and reinstalled docker for cli.

I tried then to follow your installation instruction but still got an error. I could resolve it by adding it to the docker group like explained here: https://stackoverflow.com/questions/48957195/how-to-fix-docker-got-permission-denied-issue