重构:模块化项目结构,分离配置、路由、摄像头管理器,添加健康检查,更新Dockerfile和启动脚本

This commit is contained in:
Hao Wang
2025-12-07 02:07:14 +08:00
parent e991e0e7e6
commit c4735c0d3f
21 changed files with 761 additions and 5 deletions

View File

@@ -28,9 +28,9 @@ RUN mkdir -p /var/log/multi_camera
# 暴露端口
EXPOSE 5002
# 健康检查
# 健康检查(使用/health端点
HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \
CMD curl -f http://localhost:5002/status || exit 1
CMD curl -f http://localhost:5002/health || exit 1
# 设置启动命令
CMD ["python3", "complete_multi_camera_app.py"]
CMD ["python3", "run.py"]