Files
JuiceWorkStation/docker-compose.yml
T
xiaozhou233 5b3f40fc7b feat: 后端由 Spring Boot 重写为 Go
- backend: 使用 Go + gopsutil 重写,接口 GET /api/system/stats 结构与前端保持一致
- 内存占用从 ~178MiB 降至 ~4MiB,镜像从 200MB+ 降至 15MB
- Dockerfile 改为多阶段构建,运行镜像使用 distroless
- 前端 os.javaVersion 字段改为 os.goVersion,标签由 Java 改为 Go
- docker-compose: 为 backend 与 frontend 增加 mem_limit
2026-10-06 13:38:25 +08:00

28 lines
665 B
YAML

services:
backend:
build:
context: ./backend
image: workstation-server:${BUILD_NUMBER:-latest}
container_name: workstation-server
restart: unless-stopped
expose:
- "9018"
mem_limit: 128m
frontend:
build:
context: ./dashboard
args:
BUILD_NUMBER: ${BUILD_NUMBER:-latest}
COMMIT: ${COMMIT_SHORT:-unknown}
BRANCH: ${GIT_BRANCH:-unknown}
BUILD_TIME: ${BUILD_TIME:-unknown}
image: workstation-dashboard:${BUILD_NUMBER:-latest}
container_name: workstation-dashboard
restart: unless-stopped
mem_limit: 128m
depends_on:
- backend
ports:
- "9019:80"