Skip to content

Commit

Permalink
Merge pull request #33 from Dot-Liu/master
Browse files Browse the repository at this point in the history
修改节点启动文件
  • Loading branch information
Eolink authored Nov 6, 2019
2 parents 2e19c8c + 497bc38 commit 7206829
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions build/node/resources/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,12 @@ start() {
fi

ADMIN=$1
PORT=$2
INSTANCE=$2

if [[ "$PORT" = "" ]] ;then
PORT=${ENV_PORT}
fi
if [[ "$PORT" = "" ]] ;then
PORT="6689"
if [[ "INSTANCE" = "" ]] ;then
PORT=${ENV_INSTANCE}
fi

if [[ "$ADMIN" = "" ]] ; then
ADMIN=${ENV_ADMIN}
fi
Expand All @@ -52,7 +50,7 @@ start() {
else
time=$(date "+%Y%m%d-%H%M%S")
## Change from /dev/null to something like /var/log/$PROG if you want to save output.
nohup $PROG_PATH/$PROG --port=$PORT --admin=$ADMIN 2>&1 >"$WORK_PATH/logs/stdout-$PROG-$time.log" & pid=$!
nohup $PROG_PATH/$PROG --instance=$INSTANCE --admin=$ADMIN 2>&1 >"$WORK_PATH/logs/stdout-$PROG-$time.log" & pid=$!

echo "$PROG started"
echo $pid > "$WORK_PATH/$PROG.pid"
Expand Down

0 comments on commit 7206829

Please sign in to comment.