huaweicloud-devkit 1.1.17 → 1.1.18

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/README.md CHANGED
@@ -301,6 +301,7 @@ What it provisions:
301
301
  - Generated auth password at `<install-path>/devkit/server/.auth-password` (0600, owned by the service user); every RPC requires `Authorization: Bearer <password>` or `x-devkit-password: <password>` — `GET /health` stays open for probes
302
302
  - Self-contained runtime under `<install-path>/devkit/app` (Node.js 22+ is auto-provisioned when missing)
303
303
  - Idempotent: re-running refreshes services; add `--rotate-password` to regenerate the password
304
+ - Side effect: re-runs and password rotation restart both services (brief downtime window); the previous password stops working as soon as the restart completes
304
305
 
305
306
  ### Install KooCLI
306
307
 
package/README.zh-CN.md CHANGED
@@ -297,6 +297,7 @@ sudo npx --yes huaweicloud-devkit uninstall-server # 追加 --remove-us
297
297
  - 自动生成的鉴权密码 `<install-path>/devkit/server/.auth-password`(0600,属主为服务用户);所有 RPC 需携带 `Authorization: Bearer <密码>` 或 `x-devkit-password: <密码>` —— `GET /health` 保持开放供探活
298
298
  - 自包含运行时 `<install-path>/devkit/app`(缺 Node.js 22+ 时自动下载)
299
299
  - 幂等可重跑;追加 `--rotate-password` 可重新生成密码
300
+ - 重跑或轮换密码会使两个服务各重启一次(短暂停机窗口);重启完成后旧密码立即失效
300
301
 
301
302
  ### 安装 KooCLI
302
303
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "huaweicloud-devkit",
3
3
  "mcpName": "io.github.huaweicloud/huaweicloud-devkit",
4
- "version": "1.1.17",
4
+ "version": "1.1.18",
5
5
  "kooCliVersion": "7.3.12",
6
6
  "description": "Agent toolkit that helps coding agents use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities safely and accurately.",
7
7
  "type": "module",
@@ -17,7 +17,7 @@
17
17
  "mcpServers": "./.mcp.json",
18
18
  "description": "Guide coding agents to use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities with safer execution and less context.",
19
19
  "skills": "./skills/",
20
- "version": "1.1.17",
20
+ "version": "1.1.18",
21
21
  "author": {
22
22
  "name": "HuaweiCloud Mate",
23
23
  "url": "https://github.com/huaweicloud"
@@ -20,7 +20,7 @@
20
20
  "mcpServers": "./.mcp.json",
21
21
  "description": "Agent toolkit that helps coding agents use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities safely and accurately.",
22
22
  "skills": "./skills/",
23
- "version": "1.1.17",
23
+ "version": "1.1.18",
24
24
  "author": {
25
25
  "name": "HuaweiCloud Mate",
26
26
  "url": "https://github.com/huaweicloud"
@@ -17,7 +17,7 @@
17
17
  "mcpServers": "./.mcp.json",
18
18
  "description": "Guide coding agents to use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities with safer execution and less context.",
19
19
  "skills": "./skills/",
20
- "version": "1.1.17",
20
+ "version": "1.1.18",
21
21
  "author": {
22
22
  "name": "HuaweiCloud Mate",
23
23
  "url": "https://github.com/huaweicloud"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "huaweicloud-devkit",
3
- "version": "1.1.17",
3
+ "version": "1.1.18",
4
4
  "description": "Guide coding agents to use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities with safer execution and less context.",
5
5
  "author": {
6
6
  "name": "HuaweiCloud Mate",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "huaweicloud-devkit",
3
- "version": "1.1.17",
3
+ "version": "1.1.18",
4
4
  "description": "Guide coding agents to use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities with safer execution and less context.",
5
5
  "author": {
6
6
  "name": "HuaweiCloud Mate",
@@ -2,7 +2,7 @@
2
2
  "name": "huaweicloud-devkit",
3
3
  "id": "huaweicloud-devkit",
4
4
  "displayName": "HuaweiCloud DevKit",
5
- "version": "1.1.17",
5
+ "version": "1.1.18",
6
6
  "family": "bundle-plugin",
7
7
  "bundleFormat": "codex",
8
8
  "description": "Guide coding agents to use Huawei Cloud safely — KooCLI, APIs, SDKs, 28 MCP tools, skills, and safety guardrails.",
@@ -245,9 +245,21 @@ function writeUnits(installPath, { nodePath, app, port, toolPort, user, pwFile }
245
245
  runOrDie('systemctl', ['daemon-reload'], 'systemd daemon-reload');
246
246
  }
247
247
 
248
+ // Pure command plan so the service lifecycle stays unit-testable:
249
+ // `enable` marks the units for boot without starting them; a single
250
+ // `restart` then starts fresh installs AND picks up rewritten files
251
+ // (e.g. a rotated auth password) on re-runs in one systemd call.
252
+ export function planServiceCommands() {
253
+ return [
254
+ { cmd: 'systemctl', args: ['enable', BUSINESS_SERVICE_NAME, TOOL_SERVICE_NAME], label: 'enable services' },
255
+ { cmd: 'systemctl', args: ['restart', BUSINESS_SERVICE_NAME, TOOL_SERVICE_NAME], label: 'restart services' },
256
+ ];
257
+ }
258
+
248
259
  function startServices() {
249
- runOrDie('systemctl', ['enable', '--now', BUSINESS_SERVICE_NAME], 'enable business service');
250
- runOrDie('systemctl', ['enable', '--now', TOOL_SERVICE_NAME], 'enable tool service');
260
+ for (const { cmd, args, label } of planServiceCommands()) {
261
+ runOrDie(cmd, args, label);
262
+ }
251
263
  }
252
264
 
253
265
  function waitHealthy(port, timeoutMs = 15000) {