Files
jc-video-recognize/docker/Dockerfile.web
wwh 8fb58c75fe Initial commit: Video detection platform with YOLO models
Features:
- Fire detection (YOLOv10)
- Helmet detection (YOLOv8)
- Crowd detection (YOLOv8)
- Smoking detection (YOLOv8)
- Loitering detection (YOLOv8)

Tech Stack:
- Frontend: Vue 3 + Vite + Element Plus
- Backend: FastAPI + WebSocket
- Monorepo: pnpm workspace + Turbo
- Docker support included
2026-05-18 10:54:10 +08:00

32 lines
447 B
Docker

# 构建阶段
FROM node:20-alpine AS builder
WORKDIR /app
# 复制 package.json
COPY package.json ./
# 安装依赖
RUN npm install
# 复制源代码
COPY . .
# 构建
RUN npm run build
# 生产阶段
FROM nginx:alpine
# 复制构建产物
COPY --from=builder /app/dist /usr/share/nginx/html
# 复制 nginx 配置
COPY nginx.conf /etc/nginx/conf.d/default.conf
# 暴露端口
EXPOSE 80
# 启动 nginx
CMD ["nginx", "-g", "daemon off;"]