feat: 工具配置增强、站点拨测与日志中心多项改进

- 工具配置:新增卸载 API/UI、Go 工具链、流水线构建自动安装依赖
- 修复 ListTools VerifyTool 递归栈溢出导致获取工具配置失败
- Node.js Alpine 安装改用 unofficial-builds musl 预编译包与 index.json 解析 LTS
- 站点拨测:详情页路由、告警自动恢复、并发拨测与默认可观测频率
- 日志中心:RBAC、查询构建器、ES/Loki 增强与审计 request/response 展示
- 发布配置:构建节点、流水线远程执行、Deploy RBAC 导航拆分
This commit is contained in:
Logan committed 2026-07-02 07:47:33 +08:00
1 parent cde7bbe540
commit 7e1c8f583c
84 files changed
+7729 -1507

No files matched your search

@@ -62,14 +62,41 @@ export const SITE_TIME_RANGE_LABELS: Record<SiteTimeRange, string> = {
'7d': '近 7 天',
};
/** 各协议推荐默认拨测间隔(秒)// Logan.Li */
export const DEFAULT_PROBE_FREQUENCY: Record<ProbeType, number> = {
HTTP: 60,
SSL: 3600,
TCP: 120,
DNS: 300,
PING: 120,
};
/** 各协议最小拨测间隔(秒)// Logan.Li */
export const MIN_PROBE_FREQUENCY: Record<ProbeType, number> = {
HTTP: 30,
SSL: 600,
TCP: 30,
DNS: 60,
PING: 30,
};
export function defaultProbeFrequency(type: ProbeType): number {
return DEFAULT_PROBE_FREQUENCY[type] ?? 60;
}
export const probeTypeMeta: Record<ProbeType, { label: string; placeholder: string; hint: string }> = {
HTTP: { label: '目标 URL', placeholder: 'https://example.com/health', hint: 'Web 请求(支持 http/https),检测状态码与响应时间' },
SSL: { label: 'SSL 地址', placeholder: 'example.com:443 或 https://example.com', hint: 'TLS 握手检测证书(支持 host:port / https:// 域名,不发起 HTTP 请求)' },
TCP: { label: '主机:端口', placeholder: '192.168.1.1:8080 或 example.com:443', hint: 'TCP 端口连通性' },
DNS: { label: '域名', placeholder: 'example.com', hint: 'DNS 解析延迟与结果' },
PING: { label: '主机地址', placeholder: '192.168.1.1 或 example.com', hint: 'ICMP 连通性与延迟' },
PING: { label: '主机地址', placeholder: '192.168.1.1 或 example.com', hint: 'ICMP 连通性与延迟(默认 2 分钟/次)' },
};
export function probeFrequencyHint(type: ProbeType): string {
const sec = defaultProbeFrequency(type);
return `推荐 ${fmtFrequency(sec)},最小 ${fmtFrequency(MIN_PROBE_FREQUENCY[type])}`;
}
/** 拨测频率展示 // Logan.Li */
export function fmtFrequency(sec?: number): string {
if (!sec) return '--';