Add server health endpoint and status page

Backend:
- New /api/server/health endpoint returning server, paths, disk,
  mods, steamcmd, and frontend status
- Health endpoint checks directory existence/writability, disk usage,
  server binary, and frontend dist availability

Frontend:
- New Status page (route /status) with sections for Server, SteamCMD,
  Mods, Frontend, Directories (with exists/writable badges), and
  Disk Usage (with size formatting and used-percent coloring)
- Paths are clickable to copy and use start-truncation (ellipsis on
  the left) with native hover tooltip
- Health API client integration with 10s auto-refresh

Misc:
- Update .gitignore and Makefile, minor Layout nav addition
This commit is contained in:
MrFastwind
2026-07-09 15:22:43 +02:00
parent 6f782af913
commit 2d301b95b6
10 changed files with 422 additions and 15 deletions
+2 -1
View File
@@ -1,4 +1,4 @@
import type { ServerSettings, ServerPaths, ConfigInfo, Modlist, ModlistListItem, ModEntry, ModInfo } from '../types'
import type { ServerSettings, ServerPaths, ServerHealth, ConfigInfo, Modlist, ModlistListItem, ModEntry, ModInfo } from '../types'
const BASE = '/api'
@@ -24,6 +24,7 @@ export const settingsApi = {
status: () => request<{ running: boolean }>('/server/status'),
steamcmd: () => request<{ branch: string; user: string; platform: string }>('/server/steamcmd'),
paths: () => request<ServerPaths>('/server/paths'),
health: () => request<ServerHealth>('/server/health'),
}
export const configsApi = {