This commit is contained in:
eric
2026-03-28 13:27:53 -05:00
parent d34ecab19c
commit 8053c4cb6d
48 changed files with 3527 additions and 1433 deletions

View File

@@ -26,10 +26,18 @@ REPO_ROOT = Path(__file__).resolve().parent.parent
FILES = [
"src/control_plane.py",
"src/web_process_backend.py",
"src/hub_routes.py",
"src/live_config/__init__.py",
"src/live_config/loader.py",
"web.py",
"main.py",
"scripts/hardware_probe.py",
"douyin_youtube_ffplay.py",
"scripts/linux/install_hub.sh",
"scripts/linux/reinstall_live_edge.sh",
"scripts/linux/lib/common.sh",
"live-platform/tools/render_caddyfile.py",
"live-platform/tools/render_stack_env.py",
"web-console/package.json",
"web-console/package-lock.json",
"web-console/app/globals.css",
@@ -37,6 +45,9 @@ FILES = [
"web-console/app/page.tsx",
"web-console/middleware.ts",
"web-console/components/OverviewCharts.tsx",
"web-console/components/live-product/LiveControlApp.tsx",
"web-console/lib/panelUrls.ts",
"web-console/components/console/LiveConsoleWorkspace.tsx",
]
LOG_DIR = REPO_ROOT / ".deploy_logs"
@@ -189,7 +200,8 @@ def main() -> int:
py_compile = (
f"cd {REMOTE_BASE} && python3 -m py_compile web.py "
"src/control_plane.py src/web_process_backend.py "
"src/control_plane.py src/web_process_backend.py src/hub_routes.py "
"src/live_config/__init__.py src/live_config/loader.py "
"scripts/hardware_probe.py douyin_youtube_ffplay.py main.py"
)
code_py, _ = run_logged(client, log_path, "python_py_compile", py_compile, timeout=90)
@@ -215,6 +227,7 @@ def main() -> int:
restart_cmd = (
f"echo '{PASS}' | sudo -S bash -c '"
"systemctl try-restart live-console.service 2>/dev/null || true; "
"systemctl try-restart live-edge.service 2>/dev/null || true; "
"systemctl try-restart douyinyoutube.service 2>/dev/null || true; "
"systemctl try-restart douyin-live.service 2>/dev/null || true; "
"systemctl try-restart live-web.service 2>/dev/null || true; "
@@ -239,6 +252,34 @@ def main() -> int:
"echo 'curl_health_failed'",
timeout=25,
)
run_logged(
client,
log_path,
"curl_port80_root",
"curl -sS -m 12 -o /dev/null -w 'http_code=%{http_code}\\n' http://127.0.0.1/ 2>&1 || echo curl_80_fail",
timeout=20,
)
run_logged(
client,
log_path,
"chmod_reinstall_edge",
f"chmod +x {REMOTE_BASE}/scripts/linux/reinstall_live_edge.sh 2>/dev/null || true",
timeout=15,
)
run_logged(
client,
log_path,
"reinstall_live_edge",
f"echo '{PASS}' | sudo -S bash {REMOTE_BASE}/scripts/linux/reinstall_live_edge.sh",
timeout=180,
)
run_logged(
client,
log_path,
"curl_port80_after_edge",
"curl -sS -m 12 -o /dev/null -w 'http_code=%{http_code}\\n' http://127.0.0.1/ 2>&1 || echo curl_80_fail",
timeout=20,
)
run_logged(
client,