Skip to content

Instantly share code, notes, and snippets.

@thekindofme
Last active August 29, 2015 14:16
Show Gist options
  • Save thekindofme/7c0b8161bf9a01756d8c to your computer and use it in GitHub Desktop.
Save thekindofme/7c0b8161bf9a01756d8c to your computer and use it in GitHub Desktop.
Ubuntu upstart script for headless Chrome
#!upstart
#
description "chrome"
setuid deploy #run as deploy user
start on (net-device-up
and local-filesystems
and runlevel [2345])
stop on runlevel [016]
env DISPLAY=:1
exec /usr/bin/google-chrome http://localhost:9912
respawn
respawn limit 10 5
#!upstart
#
description "xvfb"
start on starting chrome
stop on stopped chrome
exec /usr/bin/Xvfb :1 -screen 0 1024x768x24
respawn
respawn limit 10 5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment