diff --git a/src/index.ts b/src/index.ts index 9163ab3..170fd3b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -199,6 +199,8 @@ class Launcher extends DataService> { const config = { message: JSON.stringify(this.config.message), signServer: this.config.signServer, + key: this.config.key, + isBelow110: this.config.isBelow110, ...bot.config, ...bot.config.gocqhttp, } @@ -408,6 +410,8 @@ namespace Launcher { host: string root?: string signServer?: string + key?: string + isBelow110?: boolean logLevel?: number template?: string message?: Dict @@ -420,6 +424,8 @@ namespace Launcher { allowCreate: true, }).description('存放账户文件的目录。').default('data/go-cqhttp/accounts'), signServer: Schema.string().description('签名服务器地址。'), + key: Schema.string().description('签名服务器密钥。').default('114514'), + isBelow110: Schema.boolean().default(false).description('签名服务器是否低于 1.1.0 版本。'), logLevel: Schema.number().description('输出日志等级。').default(2), template: Schema.string().description('使用的配置文件模板。').hidden(), message: Schema.object({ diff --git a/template.yml b/template.yml index 1fadc95..2ebdab1 100644 --- a/template.yml +++ b/template.yml @@ -37,6 +37,14 @@ account: # 服务器可使用 docker 在本地搭建或者使用他人开放的服务 sign-server: ${{ signServer }} + # 如果签名服务器的版本在1.1.0及以下, 请将下面的参数改成true + is-below-110: ${{ isBelow110 }} + + # 签名服务器所需要的apikey, 如果签名服务器的版本在1.1.0及以下则此项无效 + # 本地部署的默认为114514 + key: >- + ${{ key }} + heartbeat: # 心跳频率, 单位秒 # -1 为关闭心跳