From 61d1f3885c926925fac339f71948182ca2edc692 Mon Sep 17 00:00:00 2001 From: WangDL Date: Sun, 24 May 2026 11:47:52 +0800 Subject: [PATCH] ci: add test-run step to capture app startup errors before restart Co-Authored-By: Claude Opus 4.7 --- .gitea/workflows/deploy.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index ec9e0e1..2194a82 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -79,6 +79,11 @@ jobs: run: | cd /opt/zhixi/backend && npx prisma generate + - name: Test-run API to capture startup errors + run: | + cd /opt/zhixi/backend + timeout 5 node dist/main.js 2>&1 || true + - name: Restart API service run: | sudo systemctl restart zhixi-api