Files
Nexus/docs/changelog/2026-06-06-install-wizard-step3-credential-check.md
T
Nexus Deploy da061d35db feat(install): require MySQL/Redis credential check at wizard step 3
Add test-credentials API and UI gate before init-db writes .env.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-06 06:47:22 +08:00

1014 B

2026-06-06 — 安装向导步骤 3 账号密码预检

摘要

步骤 3 新增「检测 MySQL / Redis 连接」按钮;init-db 在写 .env 前强制校验账号密码,避免 TCP 通但 Redis/MySQL 认证失败仍进入步骤 4。

动机

用户反馈步骤 3 仅 TCP 检测,Redis 密码错误仍初始化成功,步骤 4 才失败且无法重回步骤 3。

涉及文件

  • server/api/install.pyPOST /api/install/test-credentials_credential_checksinit-db 前置校验
  • web/app/install.html — 步骤 3 检测 UI,未通过禁用「初始化数据库」
  • tests/test_security_unit.py — 新端点单测

验证

.venv/bin/pytest tests/test_security_unit.py -k install_test_credentials -q
bash deploy/sync-install-wizard-to-container.sh

向导步骤 3:错误 Redis 密码 → 检测失败;修正后检测通过 → 可初始化。

迁移 / 重启

无 DB 迁移。部署后 sync-install-wizard-to-container.shnx update --no-cache