can4hou6joeng4
|
81c46d754e
|
fix(sync): 修复自托管下无法读取 Upstash 配置
app/api/user/{sync,config} 用 @upstash/redis/cloudflare 的
Redis.fromEnv() 创建客户端。该实现只读传入的 env 参数或 Cloudflare
全局绑定,从不回退到 process.env,因此在 Docker / Node 自托管下
url 与 token 恒为 undefined,两个接口必定返回 500,跨设备同步
(收藏、历史、设置)完全不可用。认证走的是 auth.ts 里的
new Redis({ url, token }),所以登录正常,只有用户数据读写失败。
把 auth.ts 中已有的双源回退抽成 lib/server/runtime-env.ts,Redis
客户端抽成 lib/server/redis.ts,两个路由改为惰性获取共享客户端。
惰性创建同时修正了另一个隐患:Cloudflare 的 per-request 绑定在
模块求值阶段不可达,而原先客户端是在模块作用域创建的。
未配置 Upstash 时返回 503 并给出明确说明,而不是当成请求失败。
Fixes #226
|
2026-07-31 10:12:40 +08:00 |
|
kuekhaoyang
|
a1a3821538
|
fix: complete managed admin persistence
|
2026-07-21 20:50:34 +08:00 |
|
Codex
|
387da736e1
|
fix: cap PBKDF2 iterations for Cloudflare Workers
|
2026-07-20 16:13:52 +08:00 |
|
Codex
|
dd4b7c9f24
|
fix: authenticate environment admin before Redis hashing
|
2026-07-20 16:13:52 +08:00 |
|
Codex
|
b7e962b031
|
fix: read Cloudflare request environment
|
2026-07-20 16:13:51 +08:00 |
|
Codex
|
2a59e31cd4
|
fix: read admin password at runtime on Cloudflare
|
2026-07-20 16:13:51 +08:00 |
|
Codex
|
68d4fd944d
|
fix: sync managed admin password from environment
|
2026-07-20 16:13:51 +08:00 |
|
Codex
|
27d30139c1
|
fix: support Upstash Redis on Cloudflare Pages
|
2026-07-20 16:13:51 +08:00 |
|
kuekhaoyang
|
d6f2a2e3c7
|
fix login gate session loop
|
2026-07-09 17:39:46 +08:00 |
|
kuekhaoyang
|
610f57c5b0
|
fix auth sync requests after login
|
2026-07-09 16:33:44 +08:00 |
|
kuekhaoyang
|
93e6699937
|
fix: disable Vercel analytics outside Vercel
|
2026-07-09 15:07:34 +08:00 |
|
kuekhaoyang
|
a5f9293658
|
Fix managed auth force mode
|
2026-07-08 21:36:06 +08:00 |
|
 edison0817andGitHub
|
0111318f30
|
Update auth.ts
add开启托管账户环境变量
|
2026-06-03 13:33:43 +08:00 |
|
kuekhaoyang
|
19e9707041
|
Fix managed auth and source list regressions
|
2026-04-15 23:04:41 +08:00 |
|
kuekhaoyang
|
833077a1f6
|
fix(cloudflare): remove node-only site icon route
|
2026-04-12 12:23:03 +08:00 |
|
kuekhaoyang
|
5829a79ee3
|
fix: enforce compliance mode for managed deployments
|
2026-04-02 21:42:00 +08:00 |
|