Develop hsc (#58)

feature: 优化镜像构建/部署
This commit is contained in:
hhhhsc701
2025-11-06 17:14:54 +08:00
committed by GitHub
parent d84152b45f
commit f78475e29f
27 changed files with 540 additions and 304 deletions

View File

@@ -1 +0,0 @@
NGINX_CONF=./backend-with-deer-flow.conf

View File

@@ -1 +0,0 @@
NGINX_CONF=./backend.conf

View File

@@ -9,6 +9,20 @@ server {
add_header Set-Cookie "NEXT_LOCALE=zh";
location /api/synthesis/ {
proxy_pass http://datamate-backend-python:18000/api/synthesis/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
location /api/annotation/ {
proxy_pass http://datamate-backend-python:18000/api/annotation/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
location /api/ {
proxy_pass http://datamate-backend:8080/api/;
proxy_set_header Host $host;

View File

@@ -2,7 +2,7 @@ services:
# 1) backend
datamate-backend:
container_name: datamate-backend
image: datamate-backend
image: ${REGISTRY:-}datamate-backend
restart: on-failure
privileged: true
volumes:
@@ -18,7 +18,7 @@ services:
# 1) backend (Python)
datamate-backend-python:
container_name: datamate-backend-python
image: datamate-backend-python
image: ${REGISTRY:-}datamate-backend-python
restart: on-failure
privileged: true
environment:
@@ -34,13 +34,13 @@ services:
# 2) frontend(NodePort 30000)
datamate-frontend:
container_name: datamate-frontend
image: datamate-frontend
image: ${REGISTRY:-}datamate-frontend
restart: on-failure
ports:
- "30000:80" # nodePort → hostPort
volumes:
- frontend_log_volume:/var/log/datamate/frontend
- $NGINX_CONF:/etc/nginx/conf.d/backend.conf
- ${NGINX_CONF:-./backend.conf}:/etc/nginx/conf.d/backend.conf
networks: [ datamate ]
depends_on:
- datamate-backend
@@ -71,7 +71,7 @@ services:
# 3) runtime
datamate-runtime:
container_name: datamate-runtime
image: datamate-runtime
image: ${REGISTRY:-}datamate-runtime
restart: on-failure
environment:
RAY_DEDUP_LOGS: "0"
@@ -81,7 +81,6 @@ services:
MYSQL_USER: "root"
MYSQL_PASSWORD: "password"
MYSQL_DATABASE: "datamate"
PDF_FORMATTER_BASE_URL: "http://datamate-mineru:9001"
command:
- python
- /opt/runtime/datamate/operator_runtime.py
@@ -135,6 +134,8 @@ volumes:
name: datamate-operator-upload-volume
operator-runtime-volume:
name: datamate-operator-runtime-volume
mineru_log_volume:
name: datamate-mineru_log_volume
networks:
datamate:

View File

@@ -1,6 +1,6 @@
services:
deer-flow-backend:
image: deer-flow-backend
image: ${REGISTRY:-}deer-flow-backend
container_name: deer-flow-backend
env_file:
- .env
@@ -11,7 +11,7 @@ services:
- datamate
deer-flow-frontend:
image: deer-flow-frontend
image: ${REGISTRY:-}deer-flow-frontend
container_name: deer-flow-frontend
env_file:
- .env

View File

@@ -1,5 +1,3 @@
version: '3.5'
services:
etcd:
container_name: milvus-etcd