Since switching from the Windows ecosystem, I’ve sorely missed RDP. My Linux distribution + desktop environment is pretty bleeding edge, and generally speaking RDP options of Linux are quite immature by comparison.
Below are my notes while I researched and attempted multiple different remote access options.
My system for reference:
Option 1: KRDP
Outcome: No Go. Throws errors in authentication, couldn't remedy
It appears there’s a KDE Plasma native RDP service in nix packages: kdePackages.krdp
After installation and setup, I try to connect from Windows but get an error
Because of a protocol error, this session will be disconnected.
I see the following in system logs on the host machine
Digging through forums suggests there’s a necessary dependency called freerdp
to be installed. Tried installing both freerdp
and freerdp3
but no help there.
More digging suggests it’s an issue with the implementation of credential sharing within KRDP. Many people reporting same issue with no fix.
Next option…
Option 2: XRDP
Outcome: No Go. Can't even finish nix-rebuild with it enabled
Looks like it might be possible to get a plasma DE running via xRDP
Even if I got this working, it would be using the X windowing system, not Wayland which would leave me unable to hot load the live user environment, which is my goal. I may come back to this option, but for now, trying the next thing.
Option 3: Sunshine + Moonlight
Outcome: Go. Working Great!!
Sunshine is actually a game streaming service, intended mostly as an alternative to Nvidia GeForce Now but it also natively supports remote-desktop as a use case.
At first, looked very complex to set up and use according to general internet threads, but then I came across a reddit tutorial. The entirety of that tutorial wasn’t necessary for me, but then I found the top commentor’s nix module and it was just magic.
All I had to do was add an auto-start target and it now works magically for me.
Here’s my work in a single commit, note that I bundled sunshine with a “gaming” module: https://github.com/smissingham/nixos-config/commit/2ec61a5e2a3f4ce2beede67345c5716d1de6a170
Option 4: Rustdesk
Outcome: No Go. Seems like Wayland + KDE6 not supported
Nixpkgs has two available packages
rustdesk
- a gui, with all the needful features to run rustdesk remoterustdesk-server
- a relay server for ID relay, not to be confused with a headless backend
Rustdesk client throws error on connect:
Login Error. Failed to create capturer.
System logs show the following error, then a massive rust stack trace dump: