wesmiler 2 rokov pred
rodič
commit
11bb7f3084

+ 1 - 1
app/Console/Commands/SocketServer.php

@@ -366,7 +366,7 @@ class SocketServer extends Command
             if(function_exists('exec')){
                 exec('pid=$(lsof -F p  -i:'.$port.' | cut -b 2-) &&  pkill -9 $pid');
             }
-            
+
             echo "socket stop...\n";
             $date = date('Y-m-d H:i:s');
             $this->info("【{$date}】Socket:停止运行服务");

+ 6 - 0
crontab/WalletTaskStop.sh

@@ -0,0 +1,6 @@
+#!/bin/bash
+basepath=$(cd `dirname $0`; pwd)
+cd $basepath
+pidlist=`ps -ef | grep swoole:task | grep -v grep |awk '{print $2}'`
+kill -9 $pidlist
+echo '停止服务成功...'

+ 0 - 6
crontab/orderSettleStop.sh

@@ -1,6 +0,0 @@
-#!/bin/bash
-basepath=$(cd `dirname $0`; pwd)
-cd $basepath
-pidlist=`ps -ef | grep swoole | grep -v grep |awk '{print $2}'`
-kill -9 $pidlist
-echo '停止服务成功...'

+ 0 - 2
crontab/socket.sh

@@ -1,8 +1,6 @@
 #!/bin/bash
 basepath=$(cd `dirname $0`; pwd)
 cd $basepath
-#pidlist=`ps -ef | grep socket | grep -v grep |awk '{print $2}'`
-#kill -9 $pidlist
 
 nohup php ../artisan swoole:socket start >/dev/null 2>&1 &
 echo 'Socket service start...'

+ 8 - 0
crontab/socketStop.sh

@@ -0,0 +1,8 @@
+#!/bin/bash
+basepath=$(cd `dirname $0`; pwd)
+cd $basepath
+pidlist=`ps -ef | grep swoole:socket | grep -v grep |awk '{print $2}'`
+kill -9 $pidlist
+
+echo 'Socket service stop...'
+

+ 2 - 2
crontab/orderSettle.sh

@@ -1,8 +1,8 @@
 #!/bin/bash
 basepath=$(cd `dirname $0`; pwd)
 cd $basepath
-pidlist=`ps -ef | grep swoole | grep -v grep |awk '{print $2}'`
+pidlist=`ps -ef | grep swoole:task | grep -v grep |awk '{print $2}'`
 kill -9 $pidlist
 
 nohup php ../artisan swoole:task start >/dev/null 2>&1 &
-echo 'order settle runing ...'
+echo 'swoole task runing ...'

+ 6 - 0
crontab/swooleTaskStop.sh

@@ -0,0 +1,6 @@
+#!/bin/bash
+basepath=$(cd `dirname $0`; pwd)
+cd $basepath
+pidlist=`ps -ef | grep swoole:task | grep -v grep |awk '{print $2}'`
+kill -9 $pidlist
+echo '停止服务成功...'

+ 8 - 0
crontab/walletTask.sh

@@ -0,0 +1,8 @@
+#!/bin/bash
+basepath=$(cd `dirname $0`; pwd)
+cd $basepath
+pidlist=`ps -ef | grep wallet:task | grep -v grep |awk '{print $2}'`
+kill -9 $pidlist
+
+nohup php ../artisan wallet:task start >/dev/null 2>&1 &
+echo 'wallet task runing ...'