]> git.pld-linux.org Git - packages/apcupsd.git/commitdiff
- added SERVICE_RUN_NICE_LEVEL
authorSÅ‚awomir Paszkiewicz <paszczus@pld-linux.org>
Sun, 24 Oct 2004 09:02:44 +0000 (09:02 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    apcupsd.init -> 1.5
    apcupsd.sysconfig -> 1.1

apcupsd.init
apcupsd.sysconfig [new file with mode: 0644]

index 2037aca22fe16272afc259c1259689a72916af07..f75e44b7420c5ec0f57521aba393cbc73fb91e62 100644 (file)
@@ -22,6 +22,11 @@ else
        exit 0
 fi
 
+# Get service config
+if [ -f /etc/sysconfig/apcupsd ]; then
+        . /etc/sysconfig/apcupsd
+fi
+
 RETVAL=0
 # See how we were called.
 case "$1" in
@@ -30,7 +35,7 @@ case "$1" in
        # Check if the service is already running?
        if [ ! -f /var/lock/subsys/apcupsd ]; then
                msg_starting "APC UPS monitoring"
-               daemon /usr/sbin/apcupsd -f /etc/apcupsd/apcupsd.conf
+               daemon $SERVICE_RUN_NICE_LEVEL /usr/sbin/apcupsd -f /etc/apcupsd/apcupsd.conf
                RETVAL=$?
                [ $RETVAL -eq 0 ] && touch /var/lock/subsys/apcupsd
        else
diff --git a/apcupsd.sysconfig b/apcupsd.sysconfig
new file mode 100644 (file)
index 0000000..61dc3fd
--- /dev/null
@@ -0,0 +1,5 @@
+# apcupsd startup configuration file
+
+# Try to define nice-level for running apcupsd
+SERVICE_RUN_NICE_LEVEL="+5"
+
This page took 0.047586 seconds and 4 git commands to generate.