Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
description     "Start webobjects services"
author          "David LeBer"

start on runlevel [2345]
stop on runlevel [!2345]

env USER=appserver
env NEXT_ROOT=/opt
env WOTASKD_LOG_PREFIX=/var/log/webobjects/wotaskd.log

respawn
respawn limit 15 5

pre-start script
        #roll the log
        if [ -e $WOTASKD_LOG_PREFIX.log ]
        then
                cp $WOTASKD_LOG_PREFIX.log $WOTASKD_LOG_PREFIX$(date "+_%Y%m%d_%H%M%S").log
        fi
end script

script
        echo "Launching wotaskd"
        su $USER -c "$NEXT_ROOT/Library/WebObjects/JavaApplications/wotaskd.woa/wotaskd -WOPort 1085 >> $WOTASKD_LOG_PREFIX.log 2>&1"
        emit wotaskd_running
end script

...