django-utils v0.3.0 documentation

This Page


A class that encapsulates the initialization required by a well-behaved daemon. Based on the code found here:

class djutils.daemon.Daemon(object)
__init__(self, pidfile, stdin='/dev/null', stdout='/dev/null', stderr='/dev/null')
  • pidfile – full path to file in which to store pid of daemon
  • stdin – file to use for stdin
  • stdout – file to use for stdout
  • stderr – file to use for stderr

override this method with your daemon code

See an example in djutils.queue.bin.consumer