How to configure services.xrdp.defaultWindowManager for Remote Desktop?

Hello, guys, I have read this Wiki page, and find out the GUI for the remote desktop is too ugly, I want it looks the same as my local desktop.

The following trail doesn’t work sinse pkgs.plasma5 is a set …

  services.xrdp.enable = true;
  services.xrdp.defaultWindowManager = "${pkgs.plasma5}/bin/plasmashell";
  networking.firewall.allowedTCPPorts = [ 3389 ];

So, any suggestion?

1 Like

I changed my configuration as follow and it works well now:

  services.xrdp.enable = true;
  services.xrdp.defaultWindowManager = "plasmashell";
  networking.firewall.allowedTCPPorts = [ 3389 ];
1 Like

Just in case you’re curious, if you want to find out where a binary is placed in the future, you can use nix-locate (from the nix-index package) like nix-locate bin/plasmashell and it’ll tell you which package it belongs to. In this case, it’s plasma-workspace, so if you want to make the dependency on that package explicit in services.xrdp.defaultWindowManager you were close: you just need to change it to ${pkgs.plasma-workspace}/bin/plasmashell – and pkgs.plasma5.plasma-workspace should work too. You can also use nix repl "<nixpkgs>" and type plasma5 to see what it prints, or even just tab-complete it if you don’t want to evaluate it fully.

2 Likes

this works for me

services.xserver.desktopManager.xfce.enable = true;
services.xrdp.enable = true;
services.xrdp.defaultWindowManager = "${pkgs.xfce4-14.xfce4-session}/bin/xfce4-session";

This did not work for me! I checked the version of xce4 with nix-locate and xfce4-14 seems to be the correct version. Whatever I try it’s always xrdp comming up. And xrdp crashes with Remmina when loggin in. Does it have to do that I run NixOS on a virtual machine?
Plus the PC I try to connect from runs wayland?

Maybe try x11 instead of wayland?

thank you luochen for your answer!

But moving to x11 on the machine that is connecting to the server is a no go for me. I have an old Nvidia card that is only working (very)well on wayland with nuveau driver.
The NixOS PC I want to connect to has x11 with Xfce desktop.