koishi-plugin-restart-projectzomboid 6.2.13 → 6.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/index.d.ts CHANGED
@@ -1,19 +1,26 @@
1
1
  import { Context, Schema } from 'koishi';
2
2
  export declare const name = "restart-projectzomboid";
3
+ export type ProcessPriority = 'idle' | 'belowNormal' | 'normal' | 'aboveNormal' | 'high';
3
4
  export interface ServerInstance {
4
5
  name: string;
5
6
  sourceDir: string;
6
7
  targetDir: string;
7
8
  batPath: string;
8
9
  fileNames: string[];
10
+ /** 本服务器手动指定的群管理员 QQ 号 */
9
11
  allowedUsers: string[];
12
+ /** 管理员名单来源:空字符串表示手动输入,否则继承对应服务器的管理员名单 */
13
+ adminSource?: string;
10
14
  saveInterval: number;
11
15
  serverState?: 0 | 1 | 2;
12
- allowedPrivateUsers: string[];
16
+ /** @deprecated 旧版单服务器 CMD 权限,已改为全局 cmdAllowedUsers */
17
+ allowedPrivateUsers?: string[];
13
18
  bindPort: number;
14
19
  connectPort: number;
15
20
  bindGroupId: string;
16
21
  cpuAffinity?: string;
22
+ /** 进程优先级。多服同时运行时,次要服务器可设为 belowNormal */
23
+ processPriority?: ProcessPriority;
17
24
  updateInterval: number;
18
25
  logCount: number;
19
26
  enableBSU: boolean;
@@ -24,6 +31,12 @@ export interface ServerInstance {
24
31
  export interface Config {
25
32
  ipNotifyGroups: string[];
26
33
  ipCheckInterval: number;
34
+ /** 自动为未填写 cpuAffinity 的服务器分配互不重叠的 CPU 核心 */
35
+ autoCpuAffinity: boolean;
36
+ /** 自动分配 CPU 核心时保留给系统/Koishi 的核心数 */
37
+ reservedCpuCores: number;
38
+ /** 全局 CMD 权限名单:名单内的用户可以对所有服务器发送控制台指令 */
39
+ cmdAllowedUsers: string[];
27
40
  servers: ServerInstance[];
28
41
  }
29
42
  export declare const Config: Schema<Config>;