Commits

sodas tsai committed 603a4e0

Add descriptions of daemon

Comments (0)

Files changed (2)

beanstalk/static/beanstalk_init.sh

         exit ${OUT}
         ;;
     *)
-        bsjack daemon.usage
+        echo "Usage: {start|stop|reload|restart}"
         exit 1
     ;;
 esac

beanstalk/tasks/daemon.py

 @beanstalk_role('server')
 @with_settings(hide('running', 'status'))
 def start():
+    """Start the uwsgi as a daemon
+    """
     hint = 'Start beanstalk:'
     sys.stdout.write(hint)
 
 @beanstalk_role('server')
 @with_settings(hide('running', 'status'))
 def stop():
+    """Stop the uwsgi daemon
+    """
     hint = 'Stop beanstalk:'
     sys.stdout.write(hint)
 
 @beanstalk_role('server')
 @with_settings(hide('running', 'status'))
 def reload():
+    """Reload the uwsgi daemon
+    """
     hint = 'Reload beanstalk:'
     sys.stdout.write(hint)
 
 @beanstalk_role('server')
 @with_settings(hide('running', 'status'))
 def restart():
+    """Restart the uwsgi daemon
+    """
     print 'Restarting beanstalk-stack:'
     with settings(hide('warnings', 'status', 'running'), warn_only=True):
         execute(stop)
         execute(start)
-
-
-@task
-@with_settings(hide('running', 'status'))
-def usage():
-    print 'Usage: {start|stop|reload|restart}'