igorette (owner)

Fork Of

gist: 43692 by dustin Sample upstart script for a...

Revisions

gist: 43697 Download_button fork
public
Public Clone URL: git://gist.github.com/43697.git
sample-eventd-script-for-twisted
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# This is a sample script for upstart to keep a twisted project running.
# Place it in /etc/event.d/[projectname]
 
description "useful description"
author "Dustin Sallings <dustin@spy.net>"
 
start on runlevel 2
start on runlevel 3
 
stop on runlevel 0
stop on runlevel 1
stop on runlevel 4
stop on runlevel 5
stop on runlevel 6
 
chdir /path/to/project/directory
exec /usr/bin/twistd --uid=daemonuser --syslog -ny project.tac
respawn