P7: restore agent node type, agent heartbeat expiry, build-version injection, remove log/history/xray-metrics modules, optional sub port

- nodes: port node-type (traditional/agent) picker back from web-src into
  the embedded frontend; backend annotates NodeView.nodeType from
  agent_nodes bindings; fix agent-node update path (skip reachability
  probe and apiToken requirement for agent-managed nodes); restore i18n
  keys in all 13 locales; install command now uses the Gitea mirror
- jobs: expire agent-bound nodes whose agent_nodes.last_seen is older
  than max(3x heartbeat interval, 120s) = 180s; last_seen=0 (never
  registered) is left untouched; transitions reuse UpdateHeartbeat +
  node event broadcast
- config: GetBaseVersion honors ldflags-injected buildVersion; release
  builds inject 3.7.0-agent.1 so the panel no longer reports a phantom
  update against the Gitea release tag
- logger/server: remove the three log viewers (panel/xray/amneziawg),
  their API endpoints and the 10240-entry in-memory log buffer; file
  logging via lumberjack unchanged; tests assert via a new optional
  logger hook instead of the removed buffer
- server: remove system history and xray metrics modules end to end
  (endpoints, sampling appends in RefreshStatus, per-minute persist
  cron, gob snapshot/restore, XrayMetricsService); realtime status and
  per-node history are untouched
- settings: subPort may be 0/unset - subscription links are generated
  without a port while the subscription service keeps binding the
  default 2096; the settings form declares the cleared state via
  onNumber's new onClear option instead of snapping back to 1
This commit is contained in:
Muse
2026-10-21 06:44:00 +00:00
parent 2c85f85549
commit f887f47bb9
66 changed files with 1093 additions and 5129 deletions
+14 -64
View File
@@ -136,45 +136,6 @@
"currentCommit": "Commit hiện tại",
"latestCommit": "Commit mới nhất",
"updateChannelChanged": "Đã đổi kênh cập nhật",
"systemHistoryTitle": "Lịch sử hệ thống",
"historyTitleCpu": "Mức sử dụng CPU",
"historyTitleMem": "Mức sử dụng bộ nhớ",
"historyTitleNetwork": "Băng thông mạng",
"historyTitlePackets": "Gói tin mạng",
"historyTitleDisk": "I/O đĩa",
"historyTitleOnline": "Máy khách trực tuyến",
"historyTitleLoad": "Tải trung bình hệ thống (1 / 5 / 15 phút)",
"historyTitleConnections": "Kết nối đang hoạt động (TCP / UDP)",
"historyTitleDiskUsage": "Sử dụng dung lượng đĩa",
"historyTabBandwidth": "Băng thông",
"historyTabPackets": "Gói tin",
"historyTabDisk": "Đĩa I/O",
"historyTabOnline": "Trực tuyến",
"historyTabLoad": "Tải",
"historyTabConnections": "Kết nối",
"historyTabDiskUsage": "Sử dụng đĩa",
"xrayMetricsTitle": "Chỉ số Xray",
"xrayTitleHeap": "Bộ nhớ Heap đã cấp phát",
"xrayTitleSys": "Bộ nhớ dành riêng từ HĐH",
"xrayTitleObjects": "Đối tượng Heap đang hoạt động",
"xrayTitleGcCount": "Chu kỳ GC đã hoàn thành",
"xrayTitleGcPause": "Thời lượng tạm dừng GC",
"xrayTitleObservatory": "Tình trạng kết nối đi",
"xrayTabHeap": "Heap",
"xrayTabSys": "Sys",
"xrayTabObjects": "Đối tượng",
"xrayTabGcCount": "Số lần GC",
"xrayTabGcPause": "Tạm dừng GC",
"xrayTabObservatory": "Đài quan sát",
"xrayMetricsDisabled": "Điểm cuối chỉ số Xray chưa được cấu hình",
"xrayMetricsHint": "Thêm khối metrics cấp cao nhất vào cấu hình xray với tag là metrics_out và listen là 127.0.0.1:11111, sau đó khởi động lại xray.",
"xrayObservatoryEmpty": "Chưa có dữ liệu Observatory",
"xrayObservatoryHint": "Thêm khối observatory vào cấu hình xray liệt kê các tag outbound cần kiểm tra, sau đó khởi động lại xray.",
"xrayObservatoryTagPlaceholder": "Chọn outbound",
"xrayObservatoryAlive": "Hoạt động",
"xrayObservatoryDead": "Ngừng",
"xrayObservatoryLastSeen": "Lần cuối thấy",
"xrayObservatoryLastTry": "Lần thử cuối",
"connectionCount": "Số lượng kết nối",
"ipAddresses": "Địa chỉ IP",
"toggleIpVisibility": "Chuyển đổi hiển thị IP",
@@ -191,18 +152,6 @@
"panelUpdateUnknownTitle": "Không thể xác nhận việc cập nhật đã hoàn tất",
"panelUpdateUnknownDesc": "Panel không báo cáo kết quả kịp thời. Hãy tải lại trang để kiểm tra phiên bản hiện tại, hoặc kiểm tra nhật ký máy chủ.",
"dontRefresh": "Đang tiến hành cài đặt, vui lòng không làm mới trang này.",
"logs": "Nhật ký",
"accessLogs": "Nhật ký truy cập",
"autoUpdate": "Tự động cập nhật",
"amneziawgLogs": "Nhật ký AmneziaWG",
"amneziawgHandshake": "Bắt tay gần nhất",
"amneziawgInterface": "Giao diện mạng",
"amneziawgInbound": "Inbound",
"amneziawgEndpoint": "Điểm cuối",
"amneziawgIdle": "Nhàn rỗi",
"amneziawgEvents": "Sự kiện",
"amneziawgNoPeers": "Hiện không có peer AmneziaWG nào hoạt động",
"amneziawgNoEvents": "Chưa ghi nhận sự kiện AmneziaWG nào",
"config": "Cấu hình",
"backupTitle": "Sao lưu & Khôi phục",
"exportDatabase": "Sao lưu",
@@ -219,25 +168,14 @@
"importDatabasePgDesc": "Nhấn để chọn và tải lên bản sao lưu PostgreSQL (.dump), cơ sở dữ liệu SQLite (.db) hoặc tệp kết xuất di trú SQLite nhằm khôi phục cơ sở dữ liệu của bạn. Thao tác này sẽ thay thế toàn bộ dữ liệu hiện tại.",
"migrationDownload": "Tải tệp di trú",
"migrationDownloadPgDesc": "Nhấp để tải xuống cơ sở dữ liệu SQLite .db được tạo từ dữ liệu PostgreSQL của bạn, sẵn sàng chạy bảng điều khiển này trên SQLite.",
"avg": "TB",
"peak": "đỉnh",
"free": "trống",
"openSockets": "socket đang mở",
"throughputSub": "Tổng theo giao diện mạng",
"avgWindow": "Trung bình trong khoảng",
"healthWarm": "{list} — đang cao",
"healthCritical": "{list} — nguy cấp",
"panel": "Panel",
"threads": "Luồng",
"uptime": "Thời gian chạy",
"logLevelDebug": "Debug",
"logLevelInfo": "Info",
"logLevelNotice": "Notice",
"logLevelWarning": "Warning",
"logLevelError": "Error",
"accessDirect": "DIRECT",
"accessBlocked": "BLOCKED",
"accessProxy": "PROXY",
"importKeepHostSettings": "Giữ cài đặt của máy này",
"importKeepHostSettingsDesc": "Giữ nguyên địa chỉ lắng nghe, cổng, đường dẫn cơ sở, chứng chỉ và danh tính node của bảng điều khiển này thay vì lấy chúng từ tệp đã tải lên."
},
@@ -970,7 +908,19 @@
"pinnedCertPlaceholder": "SHA-256 base64 hoặc hex",
"fetchPin": "Lấy",
"pinFetched": "Đã lấy chứng chỉ hiện tại của node",
"pinFetchFailed": "Không thể lấy chứng chỉ"
"pinFetchFailed": "Không thể lấy chứng chỉ",
"nodeType": "Node Type",
"nodeTypeTraditional": "Traditional Panel Node",
"nodeTypeAgent": "Agent Lightweight Node",
"agentHint": "Agent nodes connect out to the master; no address, port or API token needed. An install command is generated on creation.",
"agentTokenTitle": "Agent Node Setup",
"agentTokenCreated": "Node {{name}} created successfully",
"agentTokenHint": "Copy the command below and run it on the node machine. This token is shown only once!",
"agentTokenInstructions": "The command downloads the installer, configures the master URL and token. The node comes online in ~30s.",
"agentTokenCopied": "Install command copied",
"agentTokenCopyFailed": "Copy failed, please copy manually",
"copyToken": "Copy Install Command",
"agentMasterUrlHint": "Master URL (used by agent to reach the master; change to public address if behind proxy):"
},
"settings": {
"defaultTag": "Mặc định",
@@ -1725,4 +1675,4 @@
"noIpRecord": "❗ Không có bản ghi IP!"
},
"email": {}
}
}