Skip to content

Instantly share code, notes, and snippets.

@dimacus
Created September 24, 2014 18:36
Show Gist options
  • Save dimacus/c07033979362fa10f870 to your computer and use it in GitHub Desktop.
Save dimacus/c07033979362fa10f870 to your computer and use it in GitHub Desktop.
#!/bin/bash -e
# allow change to pass-in display argument
DISPLAY=$1
: ${DISPLAY:=:1}
export DISPLAY
echo "Starting VNC server"
vncserver ${DISPLAY} -geometry 1280x1024
echo "=== now running ==="
ps -fwC Xvnc4 --no-header || ps -fwC Xvnc --no-header
echo
echo "=== network after $0 ==="
netstat -na | grep "LISTEN "
echo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment