summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-apps/at/files/atd.rc6')
-rw-r--r--sys-apps/at/files/atd.rc634
1 files changed, 24 insertions, 10 deletions
diff --git a/sys-apps/at/files/atd.rc6 b/sys-apps/at/files/atd.rc6
index 8e3b1395bc28..eb1d5777ee9c 100644
--- a/sys-apps/at/files/atd.rc6
+++ b/sys-apps/at/files/atd.rc6
@@ -1,17 +1,31 @@
#!/sbin/runscript
-depend() {
- need clock
+SERVICE=atd
+EXE=/usr/sbin/atd
+PIDFILE=/var/run/atd.pid
+opts="start stop restart"
+
+# See how we were called.
+
+start() {
+
+ ebegin "Starting ${SERVICE}..."
+ start-stop-daemon --start --quiet --exec ${EXE}
+ eend $?
+
}
-function start() {
- ebegin "Starting atd"
- start-stop-daemon --start --quiet --exec /usr/sbin/atd
- eend $?
+stop() {
+
+ ebegin "Shutting down ${SERVICE}..."
+ start-stop-daemon --stop --quiet --pidfile ${PIDFILE}
+ eend $?
+
}
-function stop() {
- ebegin "Shutting down atd"
- start-stop-daemon --stop --quiet --pidfile /var/run/atd.pid
- eend $?
+restart () {
+
+ stop
+ start
+
}