docs(打包): 说明客户安装器由服务端生成

This commit is contained in:
2026-09-11 18:16:49 +08:00
parent 7b7253943f
commit 750a68c49e
+4 -10
View File
@@ -19,7 +19,7 @@ cd .\SIMCAE
| 交付物 | 给谁用 | 作用 | | 交付物 | 给谁用 | 作用 |
| --- | --- | --- | | --- | --- | --- |
| Hub 更新客户端 SDK | SIMCAE 开发者 | 提供 `Launcher.exe``Updater.exe``Bootstrap.exe` 和必要运行库 | | Hub 更新客户端 SDK | SIMCAE 开发者 | 提供 `Launcher.exe``Updater.exe``Bootstrap.exe` 和必要运行库 |
| Qt IFW 交付包 ZIP | 上传到 SimCAE Hub | 包含 IFW packagerepository 和可选客户安装器,服务端会校验、注入配置发布 | | Qt IFW 交付包 ZIP | 上传到 SimCAE Hub | 包含 IFW packagerepository,服务端会校验、注入配置发布仓库并重新生成客户安装器 |
| 客户安装器 | 最终客户 | 客户从门户下载后双击安装,安装后得到 `maintenancetool.exe` | | 客户安装器 | 最终客户 | 客户从门户下载后双击安装,安装后得到 `maintenancetool.exe` |
正式主线是:开发者只上传一个 Qt IFW 交付包 ZIP,客户只从门户下载客户安装器。客户不需要手动改服务器地址、token 或 `app_config.json` 正式主线是:开发者只上传一个 Qt IFW 交付包 ZIP,客户只从门户下载客户安装器。客户不需要手动改服务器地址、token 或 `app_config.json`
@@ -263,7 +263,7 @@ if ($UpdatesContent -notmatch "<Version>$([regex]::Escape($Version))</Version>")
## 八、组装 Qt IFW 交付包 ZIP ## 八、组装 Qt IFW 交付包 ZIP
推荐上传给 SimCAE Hub 的是交付包 ZIP,它把 packagerepository 和可选安装器放在一起。 推荐上传给 SimCAE Hub 的是交付包 ZIP,它把 packagerepository 放在一起。客户安装器由服务端基于注入配置后的 package 重新生成
目录结构建议: 目录结构建议:
@@ -273,18 +273,15 @@ if ($UpdatesContent -notmatch "<Version>$([regex]::Escape($Version))</Version>")
- `repository/Updates.xml` - `repository/Updates.xml`
- `repository/com.simcae.app/` - `repository/com.simcae.app/`
- `repository/com.simcae.dap/` - `repository/com.simcae.dap/`
- `installer/SimCAE-<版本>-Windows-installer.exe`
不要依赖交付包里的 `installer/SimCAE-<版本>-Windows-installer.exe` 作为最终客户安装器。本地生成的安装器没有服务端注入的 `app_config.json`,客户直接安装后 `Launcher.exe` 会缺少服务器地址、token 和主程序配置。服务端必须配置 `SIMCAE_IFW_BINARYCREATOR_PATH`Linux 服务端生成 Windows 安装器时还必须配置 `SIMCAE_IFW_INSTALLERBASE_WINDOWS_PATH` 指向 Windows 版 `installerbase.exe`,上传后由服务端重新生成客户门户可下载的安装器。
示例命令: 示例命令:
```powershell ```powershell
$PlatformKey = "windows_x86_64-msvc" $PlatformKey = "windows_x86_64-msvc"
$Bundle = "$Build\SimCAE-Delivery-$Version-$PlatformKey" $Bundle = "$Build\SimCAE-Delivery-$Version-$PlatformKey"
$Installer = "$Build\SimCAE-$Version-Windows-installer.exe"
if (-not (Test-Path $Installer)) {
throw "缺少本次版本安装器:$Installer"
}
if (-not (Test-Path "$Build\ifw-repository\Updates.xml")) { if (-not (Test-Path "$Build\ifw-repository\Updates.xml")) {
throw "缺少 repository/Updates.xml,请先生成 IFW repository" throw "缺少 repository/Updates.xml,请先生成 IFW repository"
} }
@@ -295,9 +292,6 @@ New-Item -ItemType Directory -Force "$Bundle" | Out-Null
Copy-Item "$Build\package" "$Bundle\package" -Recurse -Force Copy-Item "$Build\package" "$Bundle\package" -Recurse -Force
Copy-Item "$Build\ifw-repository" "$Bundle\repository" -Recurse -Force Copy-Item "$Build\ifw-repository" "$Bundle\repository" -Recurse -Force
New-Item -ItemType Directory -Force "$Bundle\installer" | Out-Null
Copy-Item $Installer "$Bundle\installer\" -Force
Compress-Archive -Path "$Bundle\*" -DestinationPath "$Build\SimCAE-Delivery-$Version-$PlatformKey.zip" -Force Compress-Archive -Path "$Bundle\*" -DestinationPath "$Build\SimCAE-Delivery-$Version-$PlatformKey.zip" -Force
``` ```