#!/bin/bash # script to install freenx ppa and package # this script should be run as root with with "sudo" if [ `id -u` != "0" ]; then echo "Sorry, you are not root." exit 1 fi # add the freenx ppa repository list echo -e 'deb http://ppa.launchpad.net/freenx-team/ppa/ubuntu jaunty main\ndeb-src http://ppa.launchpad.net/freenx-team/ppa/ubuntu jaunty main' >> /etc/apt/sources.list.d/freenxppa.sources.list # add the public key of FreeNX PPA apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 2a8e3034d018a4ce # update software information apt-get update # install freenx apt-get install freenx # Now use nxsetup to install necessary files and create the special user "nx" /usr/lib/nx/nxsetup --install