From 709b2b6b83ec35d950aebdf1482c313d0af981f4 Mon Sep 17 00:00:00 2001 From: seagull <24163551@qq.com> Date: Tue, 10 Mar 2020 17:50:53 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E6=96=B0=E6=9B=B4=E6=96=B0.sh?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E4=B8=BAunix=E6=A0=BC=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/Resources/start_service.sh | 17 +++++++++++++++++ src/main/Resources/task.sh | 24 ++++++++++++++++++++++++ src/main/Resources/task_batch.sh | 24 ++++++++++++++++++++++++ src/main/Resources/task_onecase.sh | 24 ++++++++++++++++++++++++ src/main/Resources/web_debugcase.sh | 24 ++++++++++++++++++++++++ 5 files changed, 113 insertions(+) create mode 100644 src/main/Resources/start_service.sh create mode 100644 src/main/Resources/task.sh create mode 100644 src/main/Resources/task_batch.sh create mode 100644 src/main/Resources/task_onecase.sh create mode 100644 src/main/Resources/web_debugcase.sh diff --git a/src/main/Resources/start_service.sh b/src/main/Resources/start_service.sh new file mode 100644 index 0000000..315e30b --- /dev/null +++ b/src/main/Resources/start_service.sh @@ -0,0 +1,17 @@ +#!/bin/sh +BASE_DIR="." +LIB="${BASE_DIR}/lib" +JAVA_OPTS=" -Xmx2048m -XX:PermSize=64m -XX:MaxPermSize=512m -XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:logs/gc.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=1 -XX:GCLogFileSize=1024k -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=logs/mtdperf.hprof -server -Dfile.encoding=UTF-8" +START_CLASS="springboot.RunService" + +echo ${LIB} + +for libfile in ${LIB}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +CLASSPATH=${BASE_DIR}:${CLASSPATH} +echo .:${CLASSPATH} ${START_CLASS} +java -cp .:${CLASSPATH} ${START_CLASS} & diff --git a/src/main/Resources/task.sh b/src/main/Resources/task.sh new file mode 100644 index 0000000..c5ca477 --- /dev/null +++ b/src/main/Resources/task.sh @@ -0,0 +1,24 @@ +#!/bin/sh +BASE_DIR="." +LIB="${BASE_DIR}/lib" +DRIVENPATH="${BASE_DIR}/$2" +JAVA_OPTS=" -Xmx2048m -XX:PermSize=64m -XX:MaxPermSize=512m -XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:logs/gc.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=1 -XX:GCLogFileSize=1024k -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=logs/mtdperf.hprof -server -Dfile.encoding=UTF-8" +START_CLASS="luckyclient.execution.RunAutomationTest $1" + +echo ${LIB} + +for libfile in ${LIB}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +for libfile in ${DRIVENPATH}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +CLASSPATH=${BASE_DIR}:${CLASSPATH} +echo .:${CLASSPATH} ${START_CLASS} +java -cp .:${CLASSPATH} ${START_CLASS} & diff --git a/src/main/Resources/task_batch.sh b/src/main/Resources/task_batch.sh new file mode 100644 index 0000000..fa1b474 --- /dev/null +++ b/src/main/Resources/task_batch.sh @@ -0,0 +1,24 @@ +#!/bin/sh +BASE_DIR="." +LIB="${BASE_DIR}/lib" +DRIVENPATH="${BASE_DIR}/$3" +JAVA_OPTS=" -Xmx2048m -XX:PermSize=64m -XX:MaxPermSize=512m -XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:logs/gc.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=1 -XX:GCLogFileSize=1024k -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=logs/mtdperf.hprof -server -Dfile.encoding=UTF-8" +START_CLASS="luckyclient.execution.BatchCaseExecute $1 $2" + +echo ${LIB} + +for libfile in ${LIB}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +for libfile in ${DRIVENPATH}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +CLASSPATH=${BASE_DIR}:${CLASSPATH} +echo .:${CLASSPATH} ${START_CLASS} +java -cp .:${CLASSPATH} ${START_CLASS} & diff --git a/src/main/Resources/task_onecase.sh b/src/main/Resources/task_onecase.sh new file mode 100644 index 0000000..225a2e0 --- /dev/null +++ b/src/main/Resources/task_onecase.sh @@ -0,0 +1,24 @@ +#!/bin/sh +BASE_DIR="." +LIB="${BASE_DIR}/lib" +DRIVENPATH="${BASE_DIR}/$4" +JAVA_OPTS=" -Xmx2048m -XX:PermSize=64m -XX:MaxPermSize=512m -XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:logs/gc.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=1 -XX:GCLogFileSize=1024k -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=logs/mtdperf.hprof -server -Dfile.encoding=UTF-8" +START_CLASS="luckyclient.execution.OneCaseExecute $1 $2 $3" + +echo ${LIB} + +for libfile in ${LIB}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +for libfile in ${DRIVENPATH}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +CLASSPATH=${BASE_DIR}:${CLASSPATH} +echo .:${CLASSPATH} ${START_CLASS} +java -cp .:${CLASSPATH} ${START_CLASS} & diff --git a/src/main/Resources/web_debugcase.sh b/src/main/Resources/web_debugcase.sh new file mode 100644 index 0000000..612507e --- /dev/null +++ b/src/main/Resources/web_debugcase.sh @@ -0,0 +1,24 @@ +#!/bin/sh +BASE_DIR="." +LIB="${BASE_DIR}/lib" +DRIVENPATH="${BASE_DIR}/$3" +JAVA_OPTS=" -Xmx2048m -XX:PermSize=64m -XX:MaxPermSize=512m -XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:logs/gc.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=1 -XX:GCLogFileSize=1024k -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=logs/mtdperf.hprof -server -Dfile.encoding=UTF-8" +START_CLASS="luckyclient.execution.WebDebugExecute $1 $2" + +echo ${LIB} + +for libfile in ${LIB}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +for libfile in ${DRIVENPATH}/*.jar ; do +if [ -f $libfile ] ; then + CLASSPATH=$libfile:${CLASSPATH} +fi +done + +CLASSPATH=${BASE_DIR}:${CLASSPATH} +echo .:${CLASSPATH} ${START_CLASS} +java -cp .:${CLASSPATH} ${START_CLASS} &