updated: daemon traps and exit management
This commit is contained in:
parent
c82f0fee49
commit
2c5f313d2b
5
daemon
5
daemon
|
@ -18,8 +18,7 @@ touch $ROOT/.lock;
|
||||||
|
|
||||||
# (2) Set traps before starting any subproccess
|
# (2) Set traps before starting any subproccess
|
||||||
#--------------------------------------------------------#
|
#--------------------------------------------------------#
|
||||||
trap "kill -9 $SERV_PID 2>/dev/null; pkill nc 2>/dev/null; rm $ROOT/.lock 2>/dev/null; exit 1;" INT;
|
trap "rm $ROOT/.lock 2>/dev/null; exit 1;" INT KILL;
|
||||||
trap "kill -9 $SERV_PID 2>/dev/null; pkill nc 2>/dev/null; rm $ROOT/.lock 2>/dev/null; exit 1;" KILL;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -28,5 +27,5 @@ trap "kill -9 $SERV_PID 2>/dev/null; pkill nc 2>/dev/null; rm $ROOT/.lock 2>/dev
|
||||||
# (1) Wait for trigger #
|
# (1) Wait for trigger #
|
||||||
$ROOT/com/trigger 9999;
|
$ROOT/com/trigger 9999;
|
||||||
|
|
||||||
# (2) Launch server in background #
|
# (2) Launch server #
|
||||||
$ROOT/com/launch ioemu $SATS_IP 44440 44441;
|
$ROOT/com/launch ioemu $SATS_IP 44440 44441;
|
Loading…
Reference in New Issue