Skip to content

v0.1.2 · 版本可观测 + 面板 key 提示

Choose a tag to compare

@xitihangto xitihangto released this 14 Nov 04:49
· 11 commits to main since this release

为什么需要这版

上一版排查「/panel?key= 不生效」时,无法判断容器跑的是哪个版本 —— 面板 UI 和 /healthz 都不带版本号,
结果在旧镜像上试新功能,白折腾。

改动

  • GET /healthz(无需鉴权)新增:
    • version:当前网关版本
    • api_key_required:是否启用了 api_key
    • panel_key_hint:面板直达链接模板
  • 所有响应新增 X-Longcat-Version 响应头
  • 面板标题显示版本徽标(longcat2api v0.1.2)
  • 面板启动先读 /healthz:未填 key 时立即提示;key 不对时明确提示「当前填的 key 不对」

自检一行命令

curl -s http://127.0.0.1:8090/healthz
  • 有 "version":"0.1.2" → 镜像已更新
  • 只有 status/service/accounts/time → 还是旧镜像

升级

# 把 image 的 tag 改成 0.1.2 后
docker compose pull && docker compose up -d

镜像:ghcr.io/xitihangto/longcat2api:0.1.2
(国内加速:ghcr.nju.edu.cn / ghcr.1ms.run / ghcr.dockerproxy.net 前缀)