minor: update start.bash
This commit is contained in:
parent
21113369b3
commit
65f2f640ad
14
start.bash
14
start.bash
@ -1,6 +1,14 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
# 输出日志路径
|
||||||
|
stdout_path=$(cd `dirname $0`;pwd)/stdout.log
|
||||||
|
# 1-1200秒随机延时
|
||||||
|
# 随机值$RANDOM值为1~32767
|
||||||
|
delay=$[$RANDOM%1200];
|
||||||
|
|
||||||
# 进入脚本所在目录
|
# 进入脚本所在目录
|
||||||
cd $(cd `dirname $0`;pwd)
|
cd $(cd `dirname $0`;pwd)
|
||||||
# 随机延时$RANDOM值为1~32767
|
|
||||||
sleep $[$RANDOM%1200];
|
echo "$(date) $[$delay/60]分钟后开始执行" > $stdout_path;
|
||||||
python ./main.py;
|
sleep $delay;
|
||||||
|
python3 main.py >> $stdout_path;
|
||||||
|
Loading…
Reference in New Issue
Block a user