Files
Nexus/docs/changelog/2026-05-22-wsl-mysql-bootstrap.md
T
Your Name aa65f10c52 docs: Phase 2 audit records, project memory, WSL guide
Audit docs:
- docs/reports/audit-phase-2{a-j}-line-walk.md: per-file line walk findings
- docs/reports/audit-phase-2-findings-matrix.md: 63 findings (52 fixed, 3 partial, 7 accepted)
- docs/reports/2026-05-23-full-audit-report.md: full audit consolidation
- docs/reports/audit-full-vs-phase2-reconciliation.md: cross-reference
- docs/reports/audit-phase-2-walk-closure.md: closure sign-off

Project docs:
- docs/project/phase-2-audit-remediation.md: SSOT for all fixes
- docs/project/alert-push-policy.md: dashboard alert design decisions
- docs/project/production-verification-checklist.md: first-deploy checklist
- docs/project/script-execution.md: script platform design
- docs/project/wsl-integration-test.md: WSL code-only verification guide
- docs/project/line-walk-audit-standard.md: audit methodology
- docs/project/mysql-mcp-setup.md: MCP config guide

Changelogs: 18 entries (2026-05-22 to 2026-05-23)
Project memory: CLAUDE.md, AGENTS.md updated to reflect current state
Deploy: nginx_https.conf template updated

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-23 15:27:40 +08:00

1.2 KiB
Raw Blame History

Changelog — WSL MySQL 连接 + 建表 + MCP 配置

日期: 2026-05-22
类型: 配置 / 数据库初始化

变更摘要

  1. 确认 WSL 可连接 172.31.170.47:3306,库 nexus 已存在但无表
  2. 执行 scripts/bootstrap_database.py 创建 16 张表
  3. server/config.pySettingsConfigDict(extra="ignore"),允许 .env 共存 MYSQL_*
  4. .cursor/mcp.json 改为经 WSL 启动 mysql-mcp-server
  5. 新增 scripts/wsl_check_mysql.pyscripts/bootstrap_database.py

表结构(已创建)

admins, audit_logs, command_logs, db_credentials, login_attempts, nodes, password_presets, platforms, push_retry_jobs, push_schedules, script_executions, scripts, servers, settings, ssh_sessions, sync_logs

涉及文件

  • server/config.py
  • .cursor/mcp.json
  • scripts/wsl_check_mysql.py, scripts/bootstrap_database.py
  • docs/project/mysql-mcp-setup.md

验证(WSL

python3 scripts/wsl_check_mysql.py
# 应显示 TABLES in nexus (16): [...]

备注

  • 数据迁移 migrate_category_to_node 首次可能因连接池 ping 报错(无历史数据可忽略)
  • Cursor 需 Reload Window 后 MCP 走 WSL 读 .env