DPSA/README.md
2025-05-06 20:27:07 +08:00

31 lines
638 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 需求
打开文档http://127.0.0.1:5000/apidocs/
## 项目结构规范
```
algorithm-service/
├── app/
│ ├── __init__.py # 可选
│ ├── main.py # 主应用
│ └── algorithms.py # 算法实现
├── requirements.txt # Python依赖
├── Dockerfile # Docker构建文件
└── README.md # 说明文档
```
## 镜像构建和运行
```
# 构建镜像(注意最后的点表示当前目录)
docker build -t algorithm-service .
# 后台运行(添加-d参数
docker run -p 5121:5000 --name python-algo-service algorithm-service
```