优化日志记录并改用非 root 运行

This commit is contained in:
yml2213
2026-07-29 17:01:36 +08:00
parent e5309cdf23
commit c9d0803b53
10 changed files with 102 additions and 8 deletions
+2
View File
@@ -103,6 +103,8 @@ services:
build:
context: ../backend
restart: unless-stopped
# 使用宿主机业务用户的 UID/GID,避免绑定挂载的日志被 root 创建。
user: "${BACKEND_UID:?请在 backend/.env 配置 BACKEND_UID}:${BACKEND_GID:?请在 backend/.env 配置 BACKEND_GID}"
env_file:
- ../backend/.env
environment: