On your EC2 server:
sudo apt-get update
sudo apt-get install ubuntu-desktop
Reboot your server
On your EC2 server:
sudo apt-get install tightvncserver
vncserver :1
You will be prompted for a password.
Optionally (if you hate the Ubuntu Unity desktop), on your EC2 server:
# Stop the vncserver
vncserver -kill :1
sudo apt-get install gnome-session-fallback
vim .vnc/xstartup
# This is the vncserver startup script.
# Edit the last line to read:
# /etc/X11/Xsession gnome-session-fallback
# Type :wq to save and quit vim
# Restart the vncserver
vncserver :1
On your Mac
- Create an ssh tunnel
ssh -N -L 5901:localhost:5901 -i <path to your PEM file> ubuntu@<your-ec2-server-ip>
- Open Finder
- Under the Go menu, select "Connect to Server..."
- For the Server Address, enter: vnc://localhost:5901