recipes: daemons/dbus*: Reconfigured
[dragora.git] / archive / dbus / rc.main
blob1e345ee6e6d4e8e2045ba43a130299a2158ea4a8
1 #! /bin/sh -
3 # dbus/rc.main
5 # D-Bus daemon.
8 # Redirects the standard error to the standard output
9 exec 2>&1
11 TARGET="$1"
12 SVNAME="${2:-dbus}"
14 start()
16 echo "*** ${SVNAME}: Starting dbus ..."
18 # Validate or generate unique ID file
19 /usr/bin/dbus-uuidgen --ensure=/etc/machine-id
21 exec /usr/bin/dbus-daemon --nofork --system --nopidfile
24 reset()
26 case $3 in
27 exit)
28 echo "*** ${SVNAME}: Exited status $4"
30 signal)
31 echo "*** ${SVNAME}: Killed on signal $5"
34 echo "*** ${SVNAME}: Stopped (${3})"
36 esac
39 # Branch to target
40 eval ${TARGET} "$@"