1.5 KiB
1.5 KiB
xfce_xrdp_minimal
Minimal XFCE4 + XRDP role for constrained Ubuntu/Debian VPS hosts.
What it does
- Installs only the required desktop and XRDP packages
- Installs the Xorg backend needed by XRDP (
xserver-xorg-core,xorgxrdp) - Installs open-source Chromium browser
- Installs Chinese font support (
fonts-noto-cjk) - Creates
~/.xsessionfor the target desktop user - Enables
xrdpandxrdp-sesman - Disables compositor and animations to reduce resource usage
- Optionally opens TCP
3389with UFW if UFW is present - Creates or updates the desktop user and ensures it has a usable local password for XRDP login
Variables
xfce_user: desktop login user, defaultubuntuxfce_packages: minimal package listxfce_enable_ufw: whether to allow the RDP port with UFWxfce_rdp_port: RDP port, default3389xfce_disable_compositor: defaulttruexfce_disable_animations: defaulttruexfce_user_groups: supplemental groups for the desktop user, default["sudo"]xfce_user_password_plaintext: required password for the desktop user so XRDP can authenticate
Example playbook
- hosts: vps
become: true
roles:
- role: roles/vhosts/xfce_xrdp_minimal
Manual validation
Run these on the server after connecting through RDP:
systemctl status xrdp --no-pager --full
echo "$XDG_SESSION_TYPE"
free -m
passwd -S ubuntu
Expected:
xrdpis activeXDG_SESSION_TYPE=x11- memory stays under the host budget
ubuntuis not locked and can authenticate with the password you provided