-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstall.sh
51 lines (51 loc) · 1.53 KB
/
install.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#!/bin/bash
##########################################################################
## NoMachine 3.5 + LXDE + xrdp Install Script ##
# script to fetch and install LXDE for x64/x86 debian/ubuntu
###########################################################################
## define packages
packages="lxde lxterminal midori xrdp gftp nano apt-utils software-properties-common"
##
## display welcome
clear
echo ""
echo "Welcome to LXDE & NX Installer"
echo "This script is designed to be run on a fresh install"
##
## check if root user ##
if [ $(whoami) != "root" ]; then
echo "You need to run this script as root."
echo "Use 'sudo ./autolxde.sh' then enter your password when prompted."
exit 1
fi
echo ""
## see if 32 or 64 bit ##
if [ "`uname -m | grep 64`" ]; then
V="64"
else
V=""
fi
##
echo "Updating Package List"
echo ""
apt-get update && apt-get upgrade -y
echo ""
echo "Installing Remote LXDE Desktop"
echo ""
apt-get install -y --no-install-recommends $packages
clear
## non-root user setup ##
echo "Almost there....."
echo "If you already have a non-root user, you don't have to add another."
echo ""
##
read -p "Add a new user? (y/n) " RESP
if [ "$RESP" = "y" ]; then
read -p "What would you like the username to be? " username
adduser --gecos "" $username
fi
reboot
##
echo "########################################################################"
echo "################# Install Complete #################"
echo "########################################################################"