docs: 103 发布 0630003 回退说明与备份路径
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,79 @@
|
||||
# 103 发布 0630003 — 回退说明
|
||||
|
||||
**发布编号:** `20260630-021816-92b0931`
|
||||
**Git commit:** `92b0931`(分支 `0630003`)
|
||||
**发布时间:** 2026-06-30
|
||||
|
||||
## 本次内容
|
||||
|
||||
- **MindSpace 悬浮聊天**:勾选单个文件时 Agent 获知上下文并主动问候;打开悬浮窗使用新会话
|
||||
- **悬浮聊天 UI**:统一浅色主题、固定弹窗高度、修复输入区下方空白;占位符「随时召唤你的小助手吧」13px
|
||||
- **交互**:点击页面空白收起弹窗;去掉底部关闭按钮;悬浮按钮可再次展开
|
||||
|
||||
## 103 自动备份(发布脚本已创建)
|
||||
|
||||
| 类型 | 路径(103 上) |
|
||||
|------|----------------|
|
||||
| 全量 live 备份 | `/Users/john/Project/backups/memind/memind-full-20260630-021816-92b0931-before.tar.gz` |
|
||||
| 持久目录备份 | `/Users/john/Project/backups/memind/memind-persisted-20260630-021816-92b0931-before.tar.gz` |
|
||||
| 旧源码归档 | `/Users/john/Project/archives/Memind-source-before-20260630-021816-92b0931` |
|
||||
| 当前 live | `/Users/john/Project/Memind`(无源码 runtime) |
|
||||
|
||||
**上一版 live(本发布前):** `20260630-020301-14f46cf`(commit `14f46cf`,分支 `0630002`)
|
||||
|
||||
## 健康验证
|
||||
|
||||
```bash
|
||||
ssh 58.38.22.103 'curl -sf http://127.0.0.1:8081/api/status && echo'
|
||||
```
|
||||
|
||||
**2026-06-30 发版后验证:** `ok`;live 目录为无源码 runtime(`server.mjs` + `dist/` + `scripts/run-memind-portal-prod.sh`)。
|
||||
|
||||
发版前本地已通过:
|
||||
|
||||
- `npm test -- --test-name-pattern='publish|space|billing'`
|
||||
- `npm run verify:mindspace-publish-guards:full`
|
||||
|
||||
## 回退到上一版 runtime(14f46cf / 0630002)
|
||||
|
||||
在 **103** 上执行:
|
||||
|
||||
```bash
|
||||
RELEASE_ID=20260630-021816-92b0931
|
||||
PREV_RELEASE=20260630-020301-14f46cf
|
||||
APP_DIR=/Users/john/Project/Memind
|
||||
ARCHIVE=/Users/john/Project/archives/Memind-source-before-${RELEASE_ID}
|
||||
PORTAL_LABEL=cn.tkmind.memind-portal
|
||||
LAUNCHD_GUI="gui/$(id -u)"
|
||||
|
||||
launchctl bootout "${LAUNCHD_GUI}/${PORTAL_LABEL}" 2>/dev/null || true
|
||||
lsof -tiTCP:8081 -sTCP:LISTEN | xargs kill -9 2>/dev/null || true
|
||||
|
||||
mv "${APP_DIR}" "${APP_DIR}.failed-runtime-${RELEASE_ID}"
|
||||
tar -xzf /Users/john/Project/backups/memind/memind-full-${PREV_RELEASE}-before.tar.gz -C /Users/john/Project
|
||||
|
||||
launchctl bootstrap "${LAUNCHD_GUI}" "${HOME}/Library/LaunchAgents/${PORTAL_LABEL}.plist"
|
||||
launchctl kickstart -k "${LAUNCHD_GUI}/${PORTAL_LABEL}"
|
||||
curl -sf http://127.0.0.1:8081/api/status
|
||||
```
|
||||
|
||||
## 从全量 tar 恢复(极端情况)
|
||||
|
||||
从**本发布前**全量备份恢复(即回到 `14f46cf` 上线前的 live 快照):
|
||||
|
||||
```bash
|
||||
cd /Users/john/Project
|
||||
mv Memind "Memind.broken-$(date +%Y%m%d-%H%M%S)"
|
||||
tar -xzf backups/memind/memind-full-20260630-021816-92b0931-before.tar.gz
|
||||
# 再启动 Portal LaunchAgent
|
||||
```
|
||||
|
||||
若 runtime 切换失败,发布脚本 remote 段内置 `trap rollback` 会自动尝试恢复。
|
||||
|
||||
## 本地复现 / 再发版
|
||||
|
||||
```bash
|
||||
git checkout 0630003
|
||||
npm run verify:mindspace-publish-guards:full
|
||||
bash scripts/release-portal-runtime-prod.sh --yes
|
||||
```
|
||||
Reference in New Issue
Block a user