feat: add upgrade and migration flow for native fnOS

This commit is contained in:
2026-10-02 15:49:19 +08:00
parent 57ea2b29f4
commit 27bc5d0353
8 changed files with 214 additions and 9 deletions
+28 -2
View File
@@ -11,7 +11,7 @@
构建过程不再引用 `F:\Fonu-main\havline`。
阶段三范围:
阶段四范围:
- Go 主程序原生运行
- 统一网关 `/app/havline`
@@ -22,6 +22,10 @@
- Nginx 依赖库与 `mime.types`
- HTTP 18080 与 HTTPS 9443
- frpc 与 cloudflared 按需下载,不打包进 FPK
- Native 版本 1.9.1
- Docker 版数据目录兼容
- 旧 `data/` 布局自动迁移
- 升级前数据库备份
按需下载位置:
@@ -44,6 +48,28 @@ havline:1.9.0 arm64
如果本地没有对应架构镜像,先加载 amd64 与 arm64 镜像归档。
Nginx 提取镜像版本默认固定为 `1.9.0`,与应用版本解耦。需要时可传入:
```powershell
.\build.ps1 -NginxImageVersion 1.9.0
```
## 升级与迁移
详细步骤见:
```text
docs/upgrade-and-migration.md
```
推荐路径:
```text
卸载 Docker 版时保留数据
安装 Native 1.9.1
启动后自动迁移数据库和旧数据布局
```
## 构建
```powershell
@@ -54,7 +80,7 @@ cd F:\Fonu-main\fnos-native
输出:
```text
dist/havline-native-1.9.0.fpk
dist/havline-native-1.9.1.fpk
```
构建脚本会: