aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/at/at-3.1.12/init
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/at/at-3.1.12/init')
-rw-r--r--recipes/at/at-3.1.12/init38
1 files changed, 38 insertions, 0 deletions
diff --git a/recipes/at/at-3.1.12/init b/recipes/at/at-3.1.12/init
new file mode 100644
index 0000000000..c3be80c64e
--- /dev/null
+++ b/recipes/at/at-3.1.12/init
@@ -0,0 +1,38 @@
+#!/bin/sh
+#
+# Starts at daemon
+#
+
+umask 077
+
+start() {
+ echo -n "Starting atd: "
+ start-stop-daemon --start --quiet --make-pidfile --pidfile /var/run/atd.pid --background --exec /usr/sbin/atd -- -f
+ echo "OK"
+}
+stop() {
+ echo -n "Stopping atd: "
+ start-stop-daemon --stop --quiet --pidfile /var/run/atd.pid
+ echo "OK"
+}
+restart() {
+ stop
+ start
+}
+
+case "$1" in
+ start)
+ start
+ ;;
+ stop)
+ stop
+ ;;
+ restart|reload)
+ restart
+ ;;
+ *)
+ echo $"Usage: $0 {start|stop|restart}"
+ exit 1
+esac
+
+exit $?