From 60d4a74a751768cb6196aa10f5d95d5aabb0a74e Mon Sep 17 00:00:00 2001 From: chrys Date: Wed, 19 Oct 2016 23:56:53 +0200 Subject: [PATCH] cleanup move demo application to play zone --- play zone/daemon.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 play zone/daemon.py diff --git a/play zone/daemon.py b/play zone/daemon.py new file mode 100644 index 00000000..52a58e3d --- /dev/null +++ b/play zone/daemon.py @@ -0,0 +1,12 @@ +from time import sleep +from daemonize import Daemonize + +pid = "/tmp/test.pid" + + +def main(): + while True: + sleep(5) + +daemon = Daemonize(app="test_app", pid=pid, action=main) +daemon.start()