mirror of
https://github.com/JefferyHcool/BiliNote.git
synced 2026-06-12 03:00:09 +08:00
chore(deploy): docker 镜像源/restart 策略 + .env 修正 + 文档
- 所有 Dockerfile 加 BASE_REGISTRY build-arg,国内拉不到 docker.io 时可换 daocloud 等镜像源;compose 透传该 arg - docker-compose: restart 从 on-failure:3 改 unless-stopped(避免短暂 崩溃后永久打死);gpu compose 补齐 healthcheck/restart/mem_limit - Dockerfile.complete: supervisord 用 %(ENV_*)s 透传环境变量给 backend 子进程(之前只白名单 2 个,docker run -e 配的变量后端看不到) - .env.example: 修正 VITE_API_BASE_URL 端口(8000→8483)、 WHISPER_MODEL_SIZE medium→tiny(首次启动不被大模型下载卡住)、 补 Docker 部署说明注释 - README: 新增 Docker 部署常见问题 FAQ(镜像源/restart/数据持久化等) - CLAUDE.md: 勘误(移除不存在的 messaging/i18n/worker_registry 描述, 修正 events 路径),补 pytest/typecheck 命令 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
FROM python:3.11-slim
|
||||
# BASE_REGISTRY 默认走 docker.io;国内拉不到 docker.io 时可换 daocloud / 阿里云 / 自建镜像源:
|
||||
# docker-compose build --build-arg BASE_REGISTRY=docker.m.daocloud.io
|
||||
# 或写到 docker-compose.yml 的 build.args / 环境变量里
|
||||
ARG BASE_REGISTRY=docker.io
|
||||
FROM ${BASE_REGISTRY}/library/python:3.11-slim
|
||||
|
||||
ARG APT_MIRROR=mirrors.tuna.tsinghua.edu.cn
|
||||
ARG PIP_INDEX=https://pypi.tuna.tsinghua.edu.cn/simple
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
FROM nvidia/cuda:12.4.1-cudnn-runtime-ubuntu22.04
|
||||
# BASE_REGISTRY 默认走 docker.io;国内可换 daocloud / 阿里云镜像(注意所选镜像需支持 nvidia/cuda 命名空间)
|
||||
ARG BASE_REGISTRY=docker.io
|
||||
FROM ${BASE_REGISTRY}/nvidia/cuda:12.4.1-cudnn-runtime-ubuntu22.04
|
||||
|
||||
ARG APT_MIRROR=mirrors.tuna.tsinghua.edu.cn
|
||||
ARG PIP_INDEX=https://pypi.tuna.tsinghua.edu.cn/simple
|
||||
|
||||
Reference in New Issue
Block a user