Skip to content

Instantly share code, notes, and snippets.

@Squab
Created March 9, 2015 20:03
Show Gist options
  • Save Squab/a2977f51184919cd85b3 to your computer and use it in GitHub Desktop.
Save Squab/a2977f51184919cd85b3 to your computer and use it in GitHub Desktop.
Example upstart
description "runs the celery worker"
author "Tim Simmons"
setuid celery
start on runlevel [2345]
stop on runlevel [!2345]
# retry if ended unexpectedly
respawn
# limit the retries to max 15 times with timeouts of 5 seconds
respawn limit 15 5
# Time to wait between sending TERM and KILL signals
kill timeout 20
exec celery --params
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment