Skip to content

Instantly share code, notes, and snippets.

@arindampradhan
Created October 5, 2016 09:06
Show Gist options
  • Save arindampradhan/2a763c74e9c7658f63662e51314b80db to your computer and use it in GitHub Desktop.
Save arindampradhan/2a763c74e9c7658f63662e51314b80db to your computer and use it in GitHub Desktop.
vncserver configuration .vnc/xstartup
#!/bin/sh
# Step 1 : Copy the above gist xstartup to .vns/xstartup. Remember the password you use for accessing the vncserver. Kill vncserver -> vncserver-kill :1
# Step 2 : Add the port no 5901 in your ec2 security group -> Custom TCP Rule | TCP | 5901 | 0.0.0.0/0
# Step 3 : Run tightvnc viewer, Write your public ip in remote host text box and port no. publicIp::port
sudo apt-get install ubuntu-desktop
sudo apt-get install vnc4server
sudo apt-get install gnome-panel
#!/bin/sh
# Uncomment the following two lines for normal desktop:
unset SESSION_MANAGER
# exec /etc/X11/xinit/xinitrc
gnome-session -session=gnome-classic
gnome-panel
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
x-terminal-emulator -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop"
& x-window-manager
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment