Advertisement
Guest User

Untitled

a guest
Jul 28th, 2017
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.06 KB | None | 0 0
  1. #!/bin/bash
  2. ### VARIABLES
  3. LIB=/home/icon/gpsTracksService/build
  4. CONFIG=/home/icon/services/devices
  5. JAVA="/opt/sun-jdk-1.6.0.18/bin/java"
  6. CLASSPATH="home/icon/services/devices/devices.jar:$LIB/commons-dbcp-1.2.2.jar:$LIB/commons-logging-1.0.2.jar:$LIB/commons-pool-1.5.4.jar:$LIB/gson-1.5.jar:$LIB/gtsdb.jar:$LIB/gtsutils.jar:$LIB/jdbc-postgresql.jar:$LIB/log4j-1.2.15.jar:$LIB/org.springframework.asm-3.0.2.RELEASE.jar:$LIB/org.springframework.beans-3.0.2.RELEASE.jar:$LIB/org.springframework.context-3.0.2.RELEASE.jar:$LIB/org.springframework.core-3.0.2.RELEASE.jar:$LIB/org.springframework.expression-3.0.2.RELEASE.jar:$LIB/wartools.jar:applicationContext.xml"
  7. SERVER_NAME="devices"
  8. SLOG_NAME="devices"
  9. PID_FILE="/var/run/${SLOG_NAME}.pid"
  10.  
  11. read status
  12.  
  13. if [$status eq start]; then
  14.      $echo "Starting Script Devices"
  15.      ${JAVA} -classpath "${CLASSPATH}" com.rexintegra.gps.tracks.processing.MainProcessingUnit &
  16.      javaPID=$!
  17.      $echo "'${SERVER_NAME}' backgrounded with process id '${javaPID}'"
  18.      echo ${javaPID} > ${PID_FILE}
  19. else echo "Command not found"
  20. exit 0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement