Attivare l'accesso RDP in Ubuntu: Difference between revisions

From RVM Wiki
Jump to navigation Jump to search
mNo edit summary
 
Line 1: Line 1:
=22.04=
=22.04=
* Usare script in Riferimenti, oppur:e
* Usare script in Riferimenti [https://c-nergy.be/blog/?p=18205 xRDP – Easy install xRDP on Ubuntu 18.04,20.04,22.04 (Script Version 1.4.3) – Griffon's IT Library], oppure:


* Install:
* Install:

Latest revision as of 15:53, 24 March 2023

22.04

  • Install:
sudo apt install xrdp
  • Configura:
sudo usermod -a -G ssl-cert xrdp 

Now you need to edit the /etc/xrdp/startwm.sh file. Open the XRDP file on Ubuntu 22.04 with your favorite text editor, here we use vi:

sudo vi /etc/xrdp/startwm.sh 

Add the following commands before the commands that test & execute Xsession:

Unset DBUS_SESSION_ADDRESS
Unset XDG_RUNTIME_DIR
...
if test -r /etc/profile; then
. /etc/profile
fi
Unset DBUS_SESSION_ADDRESS
Unset XDG_RUNTIME_DIRUnset
test -x /etc/X11/Xsession && exec /etc/X11/Xsession
exec /bin/sh /etc/X11/Xsession


sudo systemctl restart xrdp 
  • Fix Allow network and VPN activations
sudoedit /etc/polkit-1/localauthority/50-local.d/47-allow-wifi-scan.pkla
    [Allow Wifi Scan]
    Identity=unix-user:*
    Action=org.freedesktop.NetworkManager.wifi.scan;org.freedesktop.NetworkManager.enable-disable-wifi;org.freedesktop.NetworkManager.settings.modify.own;org.freedesktop.NetworkManager.settings.modify.system;org.freedesktop.NetworkManager.network-control
    ResultAny=yes
    ResultInactive=yes
    ResultActive=yes
  • Fix annoying Color rofile creation;
sudoedit /etc/polkit-1/localauthority.conf.d/02-allow-colord.conf


    polkit.addRule(function(action, subject) {
     if ((action.id == "org.freedesktop.color-manager.create-device" ||
     action.id == "org.freedesktop.color-manager.create-profile" ||
     action.id == "org.freedesktop.color-manager.delete-device" ||
     action.id == "org.freedesktop.color-manager.delete-profile" ||
     action.id == "org.freedesktop.color-manager.modify-device" ||
     action.id == "org.freedesktop.color-manager.modify-profile") &&
     subject.isInGroup("{users}")) {
     return polkit.Result.YES;
     }
     });


Riferimenti