Difference between revisions of "How to start a Chrome Remote Desktop session on Linux"

From UConn PAN
Jump to navigation Jump to search
(Created page with 'Google's chrome browser has a pretty good remote desktop application for chromebooks called "Chrome Remote Desktop" (CRD). CRD supports persistent sessions to Windows and Mac ho…')
 
Line 1: Line 1:
Google's chrome browser has a pretty good remote desktop application for chromebooks called "Chrome Remote Desktop" (CRD).  CRD supports persistent sessions to Windows and Mac hosts, but for Linux hosts it has to be reconfigured on a per-connection basis.  To set up a CRD session on Linux, you first need to have a remote desktop session already open (eg. VNC) in order to open a chrome browser and start the server.  It then gives you a 12 digit access code to type into the CRD client (eg. on the chromebook) to complete the connection.  That access code only lasts for the duration of a single connection; any interruption and you are back to square one.  This frequently provokes a chicken-and-egg situation, where one needs to have a remote connection to start one.
+
Google's chrome browser has a pretty good remote desktop application for chromebooks called "Chrome Remote Desktop" (CRD).  CRD supports persistent sessions to Windows and Mac hosts, but for Linux hosts it has to be reconfigured on a per-connection basis.  To set up a CRD session on Linux, you first need to have a remote desktop session already open (eg. VNC) in order to open a chrome browser and start the CRD host session.  It then gives you a 12 digit access code to type into the CRD client (eg. on the chromebook) to complete the connection.  That access code only lasts for the duration of a single connection; any interruption and you are back to square one.  This frequently provokes a chicken-and-egg situation, where one needs to have a remote connection to start one.
  
Here I provide a work-around that should make it easy and safe.  It works by requiring the user to connect first to the host using a ssh client and running a script which starts the CRD service and prints the access code to the ssh screen.  One swipe of the mouse and a paste into the CRD client access code field and the connection is complete.  This is really no different from what one does in windows to create a secure tunnel over ssh and then connecting vnc client over the tunnel.  In the case of CRD, one is relying on the secure sockets layer (https) to provide the same level of security of the session data as was provided by the ssh tunnel.
+
Here I provide a work-around that should make it easy and safe.  It works by requiring the user to connect first to the host using ssh and run a script called chromote.sh (provided below).  The chromote.sh script automatically opens a chrome browser in the user's (still invisible) X11 display on the Linux host, starts the CRD service, and prints the access code to the ssh terminal.  One swipe of the mouse and a paste into the CRD client access code field, and the connection is complete.  This is really no more work that what we used to do with Windows laptops, first creating a secure tunnel over ssh and then connecting the vnc client over the tunnel.  In the case of CRD, one is relying on the secure sockets layer (https) to provide the same level of security of the session data as was provided by the ssh tunnel.
 +
 
 +
WARNING - that access code is pretty much a key to your system, especially if you have sudo privs, so do not run this script over an unprotected connection, eg. telnet.
 +
 
 +
==The chromote.sh script==

Revision as of 22:59, 20 July 2013

Google's chrome browser has a pretty good remote desktop application for chromebooks called "Chrome Remote Desktop" (CRD). CRD supports persistent sessions to Windows and Mac hosts, but for Linux hosts it has to be reconfigured on a per-connection basis. To set up a CRD session on Linux, you first need to have a remote desktop session already open (eg. VNC) in order to open a chrome browser and start the CRD host session. It then gives you a 12 digit access code to type into the CRD client (eg. on the chromebook) to complete the connection. That access code only lasts for the duration of a single connection; any interruption and you are back to square one. This frequently provokes a chicken-and-egg situation, where one needs to have a remote connection to start one.

Here I provide a work-around that should make it easy and safe. It works by requiring the user to connect first to the host using ssh and run a script called chromote.sh (provided below). The chromote.sh script automatically opens a chrome browser in the user's (still invisible) X11 display on the Linux host, starts the CRD service, and prints the access code to the ssh terminal. One swipe of the mouse and a paste into the CRD client access code field, and the connection is complete. This is really no more work that what we used to do with Windows laptops, first creating a secure tunnel over ssh and then connecting the vnc client over the tunnel. In the case of CRD, one is relying on the secure sockets layer (https) to provide the same level of security of the session data as was provided by the ssh tunnel.

WARNING - that access code is pretty much a key to your system, especially if you have sudo privs, so do not run this script over an unprotected connection, eg. telnet.

The chromote.sh script