Commit Graph
3 Commits
Author SHA1 Message Date
opsx 9acc15f4d2 test(loki): 修正 delete_request_store 断言——两个测试互相矛盾导致 go test 必失败
现象:`go test ./services/` 在 HEAD(3a8eb52)上稳定失败
  --- FAIL: TestGeneratedLokiConfigKeepsRequiredSettingsWithoutDefaults
      deployment_config_test.go:68: required setting "delete_request_store: s3" missing

根因不是代码 bug,而是**两个测试对同一件事的期望相反**:
  backend/services/deployment_config_test.go:66  断言  delete_request_store: s3
  backend/services/loki_object_store_test.go:44  断言  delete_request_store: filesystem
而 loki_config.go 对 s3/oss/minio/cos/obs 是**刻意**用 filesystem 的
(commit 9f7c522 引入,注释:「删除请求存本地盘,避免各云 S3 兼容实现差异
导致 compactor 启动失败」)。

即:代码是有意的,loki_object_store_test 也是对的,只有 deployment_config_test
是历史遗留的过时断言。本次把它改成 filesystem,并加注释说明为什么不能再改回 s3,
避免以后有人"顺手修回去"。

运行时行为完全没有变化(只改测试文件),但修复后 `go test ./...` 才能全绿,
否则每次发版预检都会被这个假失败挡住。

验证:go test ./... 全部通过(services/models/repositories/pkg 均 ok)。
2026-10-28 15:00:30 +00:00
opsx f3733f0bfc feat: 品牌统一 LokiStack + 全站中英 i18n + 用户批量删除 + 主题定时切换与浅色侧栏
- 品牌: Go 模块/数据文件/二进制/构建部署资产全部 opsx→lokistack;前端 localStorage 命名空间迁移(读旧写新,含按用户 id 前缀迁移);修复 nginx upstream 与 Makefile 引用已改名服务的断裂
- i18n: react-i18next 落地,common + 11 个页面域命名空间全站中英(菜单/顶栏/登录/列表页/表单/确认弹窗/状态徽章);设置页语言即时切换;修复词典自注册导致的循环导入白屏
- 用户管理: 批量删除(POST /users/batch-delete,不删自己/最后管理员,部分失败不阻断)+ 行复选/全选/批量工具条
- 主题: 浅色侧栏(中性灰激活态)、四态模式(浅色/深色/跟随系统/定时切换,按时区判定)、顶栏太阳月亮二态、设置页紧凑分段选择器
- UI: 登录记住用户名、CardActionButton 统一五页卡片操作钮、shadcn Badge 替换手写徽章、语义色修正
- 清理: 移除主机 Web 终端(前后端)、k8s-helm/Helm 遗留代码与字段、README 重写精简
- 修复: 侧栏与日志告警 order 重复、路由标题 i18n key 未翻译、词典双逗号等
2026-10-27 17:11:38 +08:00
logan 2d73661dd1 feat: complete Loki query, insights, settings and deployment workflows
Add the Loki query UI, access policies, ingress insights, alert and registry settings, and their backend APIs. Include the related Kubernetes deployment and collector updates required by the integrated application.

Validated with go test ./..., npm run build, and npm run lint.
2026-10-25 21:28:32 +08:00