Files
Nexus/docs/changelog/2026-06-06-install-redis-auto-resolve.md
T

29 lines
1.1 KiB
Markdown
Raw Normal View History

# 2026-06-06 — 安装向导 Redis 自动探测 :pass@ / default
## 摘要
实测 1Panel Redis`1Panel-redis-1g6K`)支持 `redis://:pass@``default:pass`,**不支持 root**。向导取消预填 root`test-credentials` / `init-db` 自动依次尝试多种 URL 并写入可用项。
## 动机
用户 `test-1panel-redis.sh` 显示 root 失败、`:pass@` 与 default 成功;旧版预填 root 导致步骤 3 检测失败。
## 涉及文件
- `server/api/install.py``_redis_url_candidates``_resolve_redis_url`
- `web/app/install.html` — 用户名留空提示、清除 stale root
- `deploy/test-1panel-redis.sh``docs/project/nexus-1panel-operations-knowledge.md`
## 验证
```bash
pytest tests/test_security_unit.py -k "redis_url or resolve_redis" -q
bash deploy/sync-install-wizard-to-container.sh
```
步骤 3:Redis 用户名留空 + 密码 → 检测应显示「仅密码 (:pass@)」通过。
## 迁移 / 重启
`sync-install-wizard-to-container.sh``nx update`。已有错误 `.env` 手动改为 `redis://:pass@1Panel-redis-xxx:6379/0`