daemonize-doublefork: Start background daemons by double-forking

[ gpl, library, web ] [ Propose Tags ]

Start background daemons by double-forking.

See System.Posix.Daemon for documentation.

[Skip to Readme]




Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees


  • No Candidates
Versions [RSS] 0.1.0, 0.1.1
Dependencies base (>=4 && <5), directory, unix [details]
License GPL-3.0-only
Author Alexandru Scvortov <scvalex@gmail.com>
Maintainer scvalex@gmail.com
Category Web
Home page https://github.com/scvalex/daemonize-doublefork
Source repo head: git clone git://github.com/scvalex/daemonize-doublefork.git
Uploaded by AlexandruScvortov at 2011-11-27T13:38:19Z
Reverse Dependencies 1 direct, 0 indirect [details]
Downloads 2047 total (11 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs uploaded by user
Build status unknown [no reports yet]

Readme for daemonize-doublefork-0.1.0

[back to package description]


Start background Haskell daemons by double-forking


This module provides startDaemon and stopDaemon to facilitate the creation of Haskell daemon programs.

The problem is as follows: the user starts a program in their terminal, but he wants the program to relinquish control of the terminal immediately, and furthermore, the program (or part of it) should keep running even after said terminal is closed. Examples of programs that behave like this are nginx and emacs --daemon.

The correct solution is to double-fork a process. This ensures that the child process is completed separated from the terminal it was started on.

See this page for a discussion on double-forking.

See the Hackage page for documentation and examples.


This package is on Hackage. To install it, run:

cabal update
cabal install daemonize-doublefork