chore: port up
This commit is contained in:
+1
-1
@@ -11,6 +11,6 @@ COPY task_queue.py .
|
||||
COPY resident_worker.py .
|
||||
COPY config ./config
|
||||
|
||||
EXPOSE 8000
|
||||
EXPOSE 20001
|
||||
|
||||
CMD ["python", "api_server.py"]
|
||||
|
||||
+2
-2
@@ -157,11 +157,11 @@ if __name__ == "__main__":
|
||||
print("="*60)
|
||||
print("皮肤分析 API 服务")
|
||||
print("="*60)
|
||||
print("监听地址:http://0.0.0.0:8000")
|
||||
print("监听地址:http://0.0.0.0:20001")
|
||||
print("提交接口:POST /api/v1/analysis/submit")
|
||||
print("状态查询:GET /api/v1/analysis/status/{task_id}")
|
||||
print("健康检查:GET /health")
|
||||
print("="*60)
|
||||
print()
|
||||
|
||||
uvicorn.run(app, host="0.0.0.0", port=8000)
|
||||
uvicorn.run(app, host="0.0.0.0", port=20001)
|
||||
|
||||
+3
-2
@@ -3,12 +3,13 @@ from pathlib import Path
|
||||
|
||||
API_HOST = os.getenv(
|
||||
"API_HOST",
|
||||
"https://skin-test-api.ailuowan.com"
|
||||
# "https://skin-test-api.ailuowan.com"
|
||||
"https://services-test.ailuowan.com"
|
||||
)
|
||||
|
||||
API_CALLBACK = os.getenv(
|
||||
"API_CALLBACK",
|
||||
"/api/v1/analysis/callback"
|
||||
"/api/v2/analysis/py/callback"
|
||||
)
|
||||
|
||||
# SQLite must reside on persistent local storage; Compose uses /data/analysis.
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ services:
|
||||
image: skin-py-gpu:1.0.0
|
||||
working_dir: /app
|
||||
ports:
|
||||
- "8000:8000"
|
||||
- "20001:20001"
|
||||
volumes:
|
||||
- /data/www/pifu:/app
|
||||
- /data/analysis:/data/analysis
|
||||
|
||||
Reference in New Issue
Block a user