summaryrefslogtreecommitdiff
path: root/office/taskd/rc.taskd.diff
diff options
context:
space:
mode:
authorRobert Allen <slacker@engineer.com>2014-09-05 22:51:11 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2014-09-06 00:02:53 +0700
commited16becd86f3dec0cc8690d69906b1ded52c1250 (patch)
tree5fc71e796a38e172510446843cce55b32f2b8d9f /office/taskd/rc.taskd.diff
parent169f8a4fae53334e2b8222a3bb7ab1fc176e4557 (diff)
downloadslackbuilds-ed16becd86f3dec0cc8690d69906b1ded52c1250.tar.gz
office/taskd: Added (task server daemon).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'office/taskd/rc.taskd.diff')
-rw-r--r--office/taskd/rc.taskd.diff55
1 files changed, 55 insertions, 0 deletions
diff --git a/office/taskd/rc.taskd.diff b/office/taskd/rc.taskd.diff
new file mode 100644
index 0000000000..9cd4d59e41
--- /dev/null
+++ b/office/taskd/rc.taskd.diff
@@ -0,0 +1,55 @@
+--- src/taskdctl 2014-09-04 15:15:11.000000000 -0600
++++ rc.taskd 2014-09-05 00:58:33.000000000 -0600
+@@ -26,13 +26,49 @@
+ ##
+ ################################################################################
+
++################################################################################
++# SLACKWARE STARTUP:
++#
++# Before this script may be run the following conditions must be met:
++#
++# A taskd user must exist
++# The data path must exist and be owned by the taskd user
++# The data path must be set in $TASKDDATA or in /etc/taskddata
++# The server must have been previously initialized by
++# taskd init --data $TASKDDATA
++#
++# Additional configuration parameters must be valid and CA installed
++#
++# See /usr/doc/taskd-VERSION/README_SLACKWARE and man taskd for details.
++#
++# To auto start taskd at boot add these lines to /etc/rc.d/rc.local
++# if [ -x /etc/rc.d/rc.taskd ]; then
++# /etc/rc.d/rc.taskd start
++# fi
++#
++# To stop taskd at shutdown add these lines to /etc/rc.d/rc.local_shutdown
++# if [ -x /etc/rc.d/rc.taskd ]; then
++# /etc/rc.d/rc.taskd stop
++# fi
++################################################################################
++
++#Initialize from global config for convenience - SlackBuild patch
++if [ -z $TASKDDATA ] && [ -f /etc/taskddata ] ; then
++ . /etc/taskddata
++fi
++
+ if [ -z $TASKDDATA ] ; then
+- echo 'The TASKDDATA variable must be set.'
+- exit
++ echo 'The TASKDDATA variable must be set.'
++ exit
+ fi
+
+ PIDFILE=$(taskd config --data $TASKDDATA | grep pid.file | awk '{print $2}')
+-DAEMON="taskd server --data $TASKDDATA --daemon"
++DAEMON="taskd_ctl $TASKDDATA"
++
++taskd_ctl(){
++ EX="taskd server --data $1 --daemon"
++ su - taskd -c "$EX"
++}
+
+ ERROR=0
+ ARGV="$@"