28 lines
2.4 KiB
Markdown
28 lines
2.4 KiB
Markdown
## Why
|
|
|
|
Server management currently presents live-looking server values that are not live: per-server players, TPS, latency, CPU, memory, and disk are projected from deterministic platform placeholders when no Run metric sample exists. Operators also need fast log and command access from the server list without losing the safe Platform-mediated boundaries.
|
|
|
|
## What Changes
|
|
|
|
- Replace placeholder per-server metrics with latest authorized Run metric samples, including clear empty/stale states when no fresh sample exists.
|
|
- Add automatic refresh for server list and server detail operational data so cards, task status, and detail headers do not remain frozen until manual refresh.
|
|
- Update server cards to show CPU, memory, and disk with visible progress meters and replace the detail/deployment action cluster with direct `实时日志` and `管理终端` entry points while keeping `编辑部署` available only on the server list.
|
|
- Remove the low-value server detail overview surface; the detail page becomes an operations workspace focused on logs, management terminal, runtime controls, configuration, plugin controls, AI assistance, and history.
|
|
- Introduce a safe live log drawer that tails platform log streams through cursor polling rather than exposing host paths, sockets, or Run credentials.
|
|
- Register job log streams and accept the current Run spool checksum/sequence shape so stdout/stderr batches can appear in the live log drawer.
|
|
- Introduce a safe management terminal drawer that sends plugin/platform-mediated commands, starting with the existing SCUM Source RCON command path, and shows task submission/status without exposing raw shell access.
|
|
|
|
## Capabilities
|
|
|
|
### New Capabilities
|
|
- `server-live-operations-console`: Real server metric projection, refresh cadence, live log tailing, and safe management terminal behavior for 服务器管理.
|
|
|
|
### Modified Capabilities
|
|
- None.
|
|
|
|
## Impact
|
|
|
|
- Affected roots: `platform/` for per-server metric projection and job log stream compatibility, `platform_web/` for server list/detail interaction, polling, logs, terminal UI, and focused tests.
|
|
- Existing Run metric ingest, log stream cursor query, job tracking, and SCUM Source RCON command APIs are reused; no new run source tree or browser-direct shell is introduced.
|
|
- Verification: focused Go tests for metrics projection, frontend tests/typecheck/build as needed, `scripts/check-structure.sh`, and `openspec validate repair-server-live-operations-console --strict`.
|