Files
Fam Zheng 688ccdc76f
deploy notes / build-and-deploy (push) Successful in 3m40s
notes(asr): 切片串行 ASR 绕单文件大小限制
ASR server 直接 500 拒绝大文件 (15MB / ~15min 4.7s 即返回 500),不是
处理超时。改成:sidecar 装 ffmpeg → /transcribe endpoint 把音频切 60s
段 → 串行调外部 ASR → 拼接 transcript。notes 主容器 call_asr 改成 POST
到 sidecar /transcribe(timeout 1h 给长录音留余地)。

- feishu sidecar Dockerfile + ffmpeg + requests
- server.py 加 TranscribeReq;fallback -c copy 失败时 re-encode AAC
- main.rs 删除 asr_url/asr_token 字段(now sidecar concern)
- k8s manifest: ASR_URL/ASR_TOKEN 从主容器移到 feishu sidecar env
2026-05-17 22:38:05 +01:00

26 lines
891 B
Docker

# notes feishu sidecar:跑 markdown-to-feishu 把会议纪要 push 飞书 docx。
# 跟 notes 主容器同 pod、共享 PVC(看到主容器在 /data/feishu-tmp/<id>/ 写好的 md + 附件)。
FROM node:20-slim
RUN apt-get update && apt-get install -y --no-install-recommends \
python3 python3-pip python3-markdown ca-certificates curl ffmpeg \
&& rm -rf /var/lib/apt/lists/*
# lark-cli postinstall 调 curl 下二进制,没 curl 会报 spawnSync ENOENT
RUN npm install -g @larksuite/cli@1.0.29
RUN pip install --no-cache-dir --break-system-packages \
fastapi==0.115.6 \
uvicorn==0.34.0 \
requests==2.32.3
COPY markdown-to-feishu /usr/local/bin/markdown-to-feishu
RUN chmod +x /usr/local/bin/markdown-to-feishu
COPY server.py /app/server.py
ENV PYTHONUNBUFFERED=1
WORKDIR /app
EXPOSE 8002
CMD ["uvicorn", "server:app", "--host", "0.0.0.0", "--port", "8002"]