feat(deploy): Docker镜像支持页面抓取(Playwright+Chromium+scripts/)+full_sync可移植

- Dockerfile:Chromium headless 系统依赖 + playwright install chromium
  + COPY scripts/(调度器 _page_subprocess 的入口,之前镜像里没有)
- full_sync_all.sh:DB_URL 外部可覆盖(容器 MySQL)、python 路径可移植
  (容器 PATH / 本地 venv 双兼容)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
浅念
2026-08-22 10:15:58 +08:00
parent 94c2df4612
commit 3dc80805fa
2 changed files with 37 additions and 3 deletions
+8 -2
View File
@@ -1,8 +1,14 @@
#!/bin/bash
# FULL page-based re-sync: ALL channels, ALL entities — ZERO API calls, ZERO 风控
cd "$(dirname "$0")/.."
export DB_URL="sqlite+aiosqlite:///./smoke.db"
PY=".venv/Scripts/python.exe"
# DB_URL:外部已设则沿用(容器里由 docker-compose 注入 MySQL);本地默认 SQLite
export DB_URL="${DB_URL:-sqlite+aiosqlite:///./smoke.db}"
# 可移植 python:容器里 python 在 PATH;本地 Windows 用 venv 的解释器(2026-08-21 部署阻塞点#3)
if [ -f ".venv/Scripts/python.exe" ]; then
PY=".venv/Scripts/python.exe"
else
PY="python"
fi
echo "=============================================="
echo "$(date) === FULL PAGE-BASED RE-SYNC (NO API) ==="