fix bug in the shell

少写了个分号;
不能用sh,要用source,否则无法继承环境变量
This commit is contained in:
renfenghuan
2020-12-18 10:45:52 +00:00
parent d1667c199a
commit f7db9cbd75
2 changed files with 4 additions and 4 deletions

View File

@ -128,9 +128,9 @@ if [ $(grep -c "default_task.sh" $mergedListFile) -eq '0' ]; then
echo "52 */1 * * * sh /scripts/docker/default_task.sh |ts >> /scripts/logs/default_task.log 2>&1" >>$mergedListFile
fi
if [ $RANDOM_DELAY_MAX -ge 1 ] then
if [ $RANDOM_DELAY_MAX -ge 1 ]; then
echo "已设置随机延迟为 $RANDOM_DELAY_MAX , 设置延迟任务中... "
sh replaceNode_withRandomSleep.sh $mergedListFile
source replaceNode_withRandomSleep.sh $mergedListFile
fi
echo "Load the latest crontab task file..."