Changeset 25 for scripts/usr/local


Ignore:
Timestamp:
May 27, 2014, 10:32:48 AM (10 years ago)
Author:
alloc
Message:

Version 8: start-stop-daemon location by variable

Location:
scripts/usr/local/lib/7dtd
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • scripts/usr/local/lib/7dtd/VERSION

    r24 r25  
    1 Current version:        7
    2 Last edit:      2014-05-26
     1Current version:        8
     2Last edit:      2014-05-27
  • scripts/usr/local/lib/7dtd/commands/start.sh

    r23 r25  
    3939                OPTS="-quit -batchmode -nographics -configfile=$(getInstancePath $1)/config.xml -dedicated"
    4040               
    41                 start-stop-daemon --start $SSD_PID $SSD_DAEMON $SSD_USER --chdir $SDTD_BASE/engine --exec $WINE -- $SDTD_BASE/engine/7DaysToDie.exe $OPTS > $(getInstancePath $1)/stdout.log 2>&1
     41                $SSD --start $SSD_PID $SSD_DAEMON $SSD_USER --chdir $SDTD_BASE/engine --exec $WINE -- $SDTD_BASE/engine/7DaysToDie.exe $OPTS > $(getInstancePath $1)/stdout.log 2>&1
    4242                sleep 1
    4343
     
    4949                        SSD_MONITOR_PID="--pidfile $(getInstancePath $1)/monitor.pid --make-pidfile"
    5050                        SSD_MONITOR_DAEMON="--background"
    51                         start-stop-daemon --start $SSD_MONITOR_PID $SSD_MONITOR_DAEMON --exec "/usr/local/lib/7dtd/monitor-log.sh" -- "$1"
     51                        $SSD --start $SSD_MONITOR_PID $SSD_MONITOR_DAEMON --exec "/usr/local/lib/7dtd/monitor-log.sh" -- "$1"
    5252                        echo "Done!"
    5353                else
  • scripts/usr/local/lib/7dtd/commands/stop.sh

    r23 r25  
    4545                if [ $(isRunning $1) -eq 1 ]; then
    4646                        echo "Failed, force closing server..."
    47                         start-stop-daemon --stop --pidfile $(getInstancePath $1)/7dtd.pid
     47                        $SSD --stop --pidfile $(getInstancePath $1)/7dtd.pid
    4848                fi
    4949
  • scripts/usr/local/lib/7dtd/common.sh

    r23 r25  
    6161#   1 = running
    6262isRunning() {
    63         start-stop-daemon --status --pidfile $(getInstancePath $1)/7dtd.pid
     63        $SSD --status --pidfile $(getInstancePath $1)/7dtd.pid
    6464        if [ $? -eq 0 ]; then
    6565                echo 1
Note: See TracChangeset for help on using the changeset viewer.