Implemented support for daemons

Signed-off-by: Bert Hajee <hajee@moretIA.com>