2014-08-18 11:18:36 +02:00
|
|
|
diff -rupN powerman-2.3.16.old/scripts/powerman.in powerman-2.3.16/scripts/powerman.in
|
|
|
|
--- powerman-2.3.16.old/scripts/powerman.in 2012-01-12 16:37:34.000000000 -0800
|
|
|
|
+++ powerman-2.3.16/scripts/powerman.in 2014-08-04 09:40:11.063544169 -0700
|
|
|
|
@@ -34,7 +34,8 @@ DESC="PowerMan"
|
2010-05-19 09:21:49 +02:00
|
|
|
DAEMON="$sbindir/powermand"
|
|
|
|
#DAEMON_ARGS=
|
|
|
|
CONFIG=$sysconfdir/powerman/powerman.conf
|
|
|
|
-PIDFILE="$localstatedir/run/powerman/powermand.pid"
|
2014-08-18 11:18:36 +02:00
|
|
|
+PIDDIR="/run/powerman"
|
2010-05-19 09:21:49 +02:00
|
|
|
+PIDFILE="$PIDDIR/powermand.pid"
|
|
|
|
#NICE=
|
|
|
|
USER=@RUN_AS_USER@
|
|
|
|
#SIGHUP_RELOAD=
|
2014-08-18 11:18:36 +02:00
|
|
|
@@ -54,6 +55,11 @@ service_init ()
|
2010-05-19 09:21:49 +02:00
|
|
|
SIGTERM_TIMEOUT="3"
|
|
|
|
STATUS=0
|
2014-08-18 11:18:36 +02:00
|
|
|
|
|
|
|
+if [ ! -d "$PIDDIR" ] ; then
|
|
|
|
+ mkdir "$PIDDIR"
|
|
|
|
+ chown $USER $PIDDIR
|
|
|
|
+fi
|
|
|
|
+
|
2010-05-19 09:21:49 +02:00
|
|
|
# Read configuration defaults to override variables:
|
|
|
|
# $DAEMON_ARGS, $CONFIG, $PIDFILE, $USER, $NICE, $SIGHUP_RELOAD
|
|
|
|
##
|