diff --git a/modules/wsl-distro.nix b/modules/wsl-distro.nix index e75e7f01..f20bb5bd 100644 --- a/modules/wsl-distro.nix +++ b/modules/wsl-distro.nix @@ -124,6 +124,10 @@ with lib; { # Don't allow emergency mode, because we don't have a console. enableEmergencyMode = false; + + # Link the X11 socket into place. This is a no-op on a normal setup, + # but helps if /tmp is a tmpfs or mounted from some other location. + tmpfiles.rules = [ "L /tmp/.X11-unix - - - - /mnt/wslg/.X11-unix" ]; }; # Start a systemd user session when starting a command through runuser