perf: 为私有化部署默认启用资源压缩
Test deployment public URL (Linux) / test-linux (push) Waiting to run
Test start.ps1 (Windows) / test-windows (push) Waiting to run

This commit is contained in:
2026-08-04 23:35:48 +08:00
parent 9dc01e2411
commit 919a797510
3 changed files with 30 additions and 1 deletions
+5
View File
@@ -26,8 +26,13 @@ services:
# 默认的服务器websocket地址,本地不需要更改,云服务需要修改为云端IP,并放行对应端口
- NUXT_PUBLIC_BASE_SOCKETURL=${NUXT_PUBLIC_BASE_SOCKETURL}
- NUXT_APP_CDN_URL=${NUXT_APP_CDN_URL}
# 默认自动选择 CDN Brotli;CDN 不兼容时安全回退到源站预压缩资源
- STATIC_ASSET_COMPRESSION=${STATIC_ASSET_COMPRESSION:-auto}
# Agent 服务治理 API 地址(前端直接调用,走 Nginx 代理时配置为 /asg-api
- NUXT_PUBLIC_SG_APIURL=${NUXT_PUBLIC_SG_APIURL}
volumes:
# 保存与当前前端构建绑定的 CDN 验证结果,旧结果不会跨构建误用
- ./data/cdn-init:/tmp/cdn-init
# 日志大小设置,避免日志文件过大
env_file:
- .env