#!/bin/bash

PROJECT_JAR="examcloud-tool.jar"

PROJECT_JVM_ARGS="-server -Xms512m -Xmx512m"

PROJECT_ARGS="--sys.log.level=INFO"

PID_LIST=`ps -ef | grep $PROJECT_JAR | grep java | awk '{print $2}'`
if [ ! -z "$PID_LIST" ]; then
    echo "$PROJECT_JAR is already running..."
    exit -1
fi

nohup java $PROJECT_JVM_ARGS -jar $PROJECT_JAR $PROJECT_ARGS >/dev/null 2>&1 &

echo "$PROJECT_JAR start..."
