init v3 branch
This commit is contained in:
@@ -6,6 +6,7 @@ app/config.yml
|
|||||||
/config.yml
|
/config.yml
|
||||||
app/data/
|
app/data/
|
||||||
data/
|
data/
|
||||||
|
tasks/
|
||||||
skills/deps/
|
skills/deps/
|
||||||
skills/*/.deps_installed
|
skills/*/.deps_installed
|
||||||
skills/*/__pycache__/
|
skills/*/__pycache__/
|
||||||
|
|||||||
+1
-26
@@ -1,31 +1,6 @@
|
|||||||
FROM node:20-slim
|
FROM node:20-slim
|
||||||
|
|
||||||
# MPLBACKEND=Agg:让 matplotlib 使用非交互式后端,避免缺少显示设备报错。
|
ENV TZ=Asia/Shanghai
|
||||||
# PYTHONUNBUFFERED=1:实时输出日志。
|
|
||||||
# TZ=Asia/Shanghai:统一时区。
|
|
||||||
ENV MPLBACKEND=Agg \
|
|
||||||
PYTHONUNBUFFERED=1 \
|
|
||||||
PIP_BREAK_SYSTEM_PACKAGES=1 \
|
|
||||||
TZ=Asia/Shanghai
|
|
||||||
|
|
||||||
# 常用命令行工具:Agent 的 terminal 工具经常用到
|
|
||||||
RUN apt-get update -y && apt-get install -y --no-install-recommends \
|
|
||||||
ca-certificates curl git python3 python3-pip python3-venv python3-dev \
|
|
||||||
ripgrep wget jq p7zip-full unzip unar file \
|
|
||||||
libreoffice-writer libreoffice-calc libreoffice-impress \
|
|
||||||
fonts-noto-cjk fonts-dejavu fonts-stix \
|
|
||||||
poppler-utils qpdf ghostscript imagemagick \
|
|
||||||
tesseract-ocr tesseract-ocr-chi-sim \
|
|
||||||
ffmpeg sqlite3 libsqlite3-dev \
|
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
|
||||||
|
|
||||||
RUN pip3 install --no-cache-dir --break-system-packages \
|
|
||||||
requests beautifulsoup4 lxml \
|
|
||||||
numpy matplotlib \
|
|
||||||
openpyxl python-docx python-pptx xlrd \
|
|
||||||
pymupdf pdfplumber pypdf reportlab \
|
|
||||||
Pillow python-dateutil python-magic \
|
|
||||||
loguru rich fonttools
|
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
|
|||||||
+23
-7
@@ -1,14 +1,15 @@
|
|||||||
services:
|
services:
|
||||||
agent:
|
agent-core:
|
||||||
build: ./app
|
build: ./app
|
||||||
container_name: agent
|
container_name: agent-core
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
expose:
|
expose:
|
||||||
- "8080" # 仅内网暴露,由 nginx-proxy 对外
|
- "8080" # 仅内网暴露,由 nginx-proxy 对外
|
||||||
volumes:
|
volumes:
|
||||||
- ./data:/workspace/tasks # 持久化:任务目录 + SQLite(.agent.db 在此目录内)
|
- ./tasks:/workspace/tasks # 持久化:任务目录
|
||||||
- ./skills:/workspace/skills # 技能目录:所有任务/会话共享同一份技能
|
- ./skills:/workspace/skills # 技能目录:所有任务/会话共享同一份技能
|
||||||
- ./config.yml:/app/config.yml # 2.0:去掉 :ro,允许设置页写配置(写前服务端会校验)
|
- ./data:/workspace/data # 持久化:数据目录
|
||||||
|
- ./config.yml:/app/config.yml # 允许设置页写配置(写前服务端会校验)
|
||||||
- ./app/server:/app/server
|
- ./app/server:/app/server
|
||||||
environment:
|
environment:
|
||||||
- PORT=8080
|
- PORT=8080
|
||||||
@@ -16,9 +17,24 @@ services:
|
|||||||
- VIRTUAL_HOST=agent.ai.foresh.com
|
- VIRTUAL_HOST=agent.ai.foresh.com
|
||||||
- VIRTUAL_PORT=8080
|
- VIRTUAL_PORT=8080
|
||||||
- CERT_NAME=default
|
- CERT_NAME=default
|
||||||
|
# 加入executor独立服务
|
||||||
|
- EXECUTOR_URL=http://agent-executor:9000
|
||||||
networks:
|
networks:
|
||||||
- my-app-network
|
- my-app-network
|
||||||
|
|
||||||
networks:
|
agent-executor:
|
||||||
my-app-network:
|
build: ./executor
|
||||||
external: true
|
container_name: agent-executor
|
||||||
|
restart: unless-stopped
|
||||||
|
expose:
|
||||||
|
- "9000"
|
||||||
|
volumes:
|
||||||
|
- ./tasks:/workspace/tasks # 持久化:任务目录
|
||||||
|
- ./skills:/workspace/skills # 技能目录:所有任务/会话共享同一份技能
|
||||||
|
environment:
|
||||||
|
- PORT=9000
|
||||||
|
cap_drop:
|
||||||
|
- SYS_ADMIN
|
||||||
|
- DAC_OVERRIDE
|
||||||
|
networks:
|
||||||
|
- my-app-network
|
||||||
|
|||||||
@@ -0,0 +1,28 @@
|
|||||||
|
FROM node:20-slim
|
||||||
|
|
||||||
|
# MPLBACKEND=Agg:让 matplotlib 使用非交互式后端,避免缺少显示设备报错。
|
||||||
|
# PYTHONUNBUFFERED=1:实时输出日志。
|
||||||
|
# TZ=Asia/Shanghai:统一时区。
|
||||||
|
ENV MPLBACKEND=Agg \
|
||||||
|
PYTHONUNBUFFERED=1 \
|
||||||
|
PIP_BREAK_SYSTEM_PACKAGES=1 \
|
||||||
|
TZ=Asia/Shanghai
|
||||||
|
|
||||||
|
# 常用命令行工具:Agent 的 terminal 工具经常用到
|
||||||
|
RUN apt-get update -y && apt-get install -y --no-install-recommends \
|
||||||
|
ca-certificates curl git python3 python3-pip python3-venv python3-dev \
|
||||||
|
ripgrep wget jq p7zip-full unzip unar file \
|
||||||
|
libreoffice-writer libreoffice-calc libreoffice-impress \
|
||||||
|
fonts-noto-cjk fonts-dejavu fonts-stix \
|
||||||
|
poppler-utils qpdf ghostscript imagemagick \
|
||||||
|
tesseract-ocr tesseract-ocr-chi-sim \
|
||||||
|
ffmpeg sqlite3 libsqlite3-dev \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
RUN pip3 install --no-cache-dir --break-system-packages \
|
||||||
|
requests beautifulsoup4 lxml \
|
||||||
|
numpy matplotlib \
|
||||||
|
openpyxl python-docx python-pptx xlrd \
|
||||||
|
pymupdf pdfplumber pypdf reportlab \
|
||||||
|
Pillow python-dateutil python-magic \
|
||||||
|
loguru rich fonttools
|
||||||
Reference in New Issue
Block a user