添加调试

This commit is contained in:
songhao 2020-02-29 13:47:16 +08:00
parent 7a560291e3
commit 20a9680f4a
2 changed files with 22 additions and 2 deletions

View File

@ -1,5 +1,9 @@
source ./common.sh
if [ -f "custom_init.sh" ]; then
source ./custom_init.sh
fi
work_dir=`pwd`
cd ${SOURCE_PATH}
echo ${PRE_COMPILE_CMD}|sh
@ -19,4 +23,10 @@ then
touch bin/is_test_env
fi
if [[ IS_DEV_ENV -eq 1 ]]; then
rm -rf new_lib
mkdir -p new_lib
cp -rf lib/* new_lib/
else
tar --exclude=*.git -chzf target/${package_name} bin common.sh reload.sh restart.sh start_instance.sh manage.py config lib ${EXT_PKG_FILES}
fi

View File

@ -4,4 +4,14 @@ source ./common.sh
mkdir -p logs
if [ -f "custom_init.sh" ]; then
source ./custom_init.sh
fi
if [[ IS_DEV_ENV -eq 1 ]]; then
java -jar -agentlib:jdwp=transport=dt_socket,server=y,suspend=${DEBUG_SUSPEND},address=${DEBUG_PORT} \
${JAVA_OPTS} -Dinstance_id="$1" new_${JAR_NAME}
else
java -jar ${JAVA_OPTS} -Dinstance_id="$1" ${JAR_NAME} >> logs/app-$1.out 2>&1 &
fi