修复定时服务启动路径

This commit is contained in:
whyour 2023-04-08 21:58:34 +08:00
parent 6fb39ce835
commit ebb9676a51
3 changed files with 6 additions and 4 deletions

View File

@ -3,6 +3,7 @@ import { CronServiceService } from '../protos/cron';
import { addCron } from './addCron';
import { delCron } from './delCron';
import config from '../config';
import Logger from '../loaders/logger';
const server = new Server();
server.addService(CronServiceService, { addCron, delCron });
@ -11,5 +12,6 @@ server.bindAsync(
ServerCredentials.createInsecure(),
() => {
server.start();
Logger.debug(`✌️ 定时服务启动成功!`);
},
);

View File

@ -34,9 +34,9 @@ pm2 delete panel &>/dev/null
pm2 start $dir_static/build/app.js -n panel --source-map-support --time
echo -e "主服务启动成功...\n"
echo -e "======================6. 启动定时务========================\n"
echo -e "======================6. 启动定时务========================\n"
pm2 delete schedule &>/dev/null
pm2 start $dir_static/build/schedule.js -n schedule --source-map-support --time
pm2 start $dir_static/build/schedule/index.js -n schedule --source-map-support --time
echo -e "定时任务启动成功...\n"
if [[ $AutoStartBot == true ]]; then

View File

@ -379,9 +379,9 @@ reload_pm2() {
pm2 delete panel --source-map-support --time &>/dev/null
pm2 start $dir_static/build/app.js -n panel --source-map-support --time &>/dev/null
echo -e "启动定时任务服务\n"
echo -e "启动定时服务\n"
pm2 delete schedule --source-map-support --time &>/dev/null
pm2 start $dir_static/build/schedule.js -n schedule --source-map-support --time &>/dev/null
pm2 start $dir_static/build/schedule/index.js -n schedule --source-map-support --time &>/dev/null
}
diff_time() {