SilveryStar/Adachi-BOT

windows部署到运行这一阶段输入npm start后报错

fwy55186228 opened this issue · 1 comments

系统版本

windows server 2012r2

Node.js 版本

v14.17.2

应用版本

2.2.12-bugfix2

启动方式

Forever

复述操作

跟着https://docs.adachi.top/deploy/windows.html#%E4%B8%8B%E8%BD%BD 教程到了运行这一阶段 输入npm start后报错

配置文件

setting配置文件
tip: 前往 https://docs.adachi.top/config 查看配置详情
qrcode: false
number: 3******6
password: "f*****.."
master: 893***3
header: "#"
platform: 1
atUser: false
atBOT: false
inviteAuth: master
countThreshold: 60
groupIntervalTime: 1500
privateIntervalTime: 2000
helpMessageStyle: message
logLevel: info
dbPort: 6379
webConsole:
  enable: true
  consolePort: 80
  tcpLoggerPort: 54921
  jwtSecret: ""

redis.conf
stop-writes-on-bgsave-error no
rdbcompression no
dbfilename dump.rdb

appendonly yes
appendfsync everysec
no-appendfsync-on-rewrite no
auto-aof-rewrite-percentage 100
auto-aof-rewrite-min-size 64mb

port 6379
dir /data/

错误报告

> adachi-bot@2.2.12-bugfix2 start C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master
> ts-node -r tsconfig-paths/register app.ts --files


C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\node_modules\_express-jwt@6.1.1@express-jwt\lib\index.js:20
  if (!options || !options.secret) throw new Error('secret should be set');
                                         ^
Error: secret should be set
    at module.exports (C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\node_modules\_express-jwt@6.1.1@express-jwt\lib\index.js:20:42)
    at Function.WebConsole.JWT (C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\src\web-console\backend\index.ts:87:13)
    at WebConsole.useApi (C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\src\web-console\backend\index.ts:104:35)
    at WebConsole.createConsole (C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\src\web-console\backend\index.ts:38:8)
    at new WebConsole (C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\src\web-console\backend\index.ts:27:8)
    at new Adachi (C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\src\modules\bot.ts:60:4)
    at Object.<anonymous> (C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\app.ts:3:16)
    at Module._compile (internal/modules/cjs/loader.js:1085:14)
    at Module.m._compile (C:\Users\Administrator\Desktop\yuanshen\Adachi-BOT-master\node_modules\_ts-node@9.1.1@ts-node\src\index.ts:1056:23)
    at Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! adachi-bot@2.2.12-bugfix2 start: `ts-node -r tsconfig-paths/register app.ts --files`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the adachi-bot@2.2.12-bugfix2 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Administrator\AppData\Roaming\npm-cache\_logs\2022-04-10T03_56_45_448Z-debug.log