From 82c41ccec639b8fdcdc74acde099c600f413f86f Mon Sep 17 00:00:00 2001 From: claude_code Date: Mon, 29 Jun 2026 00:06:14 +0300 Subject: [PATCH] ci: add timeout limits to CI jobs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Set explicit `timeout-minutes` for develop and test workflows to prevent jobs from running indefinitely and to cap resource usage. This includes a hard‑cap for the e2e‑server job, which can leak open handles and cause hangs. --- .github/workflows/develop.yml | 4 ++++ .github/workflows/test.yml | 1 + 2 files changed, 5 insertions(+) diff --git a/.github/workflows/develop.yml b/.github/workflows/develop.yml index 35a5a367..c4df52b8 100644 --- a/.github/workflows/develop.yml +++ b/.github/workflows/develop.yml @@ -25,6 +25,7 @@ jobs: build: needs: test runs-on: ubuntu-latest + timeout-minutes: 30 steps: - name: Checkout uses: actions/checkout@v4 @@ -65,6 +66,8 @@ jobs: # deploy block. e2e-server: runs-on: ubuntu-latest + # Hard cap: the full-AppModule e2e leaks open handles and hung jest to the 6h max. + timeout-minutes: 15 env: DATABASE_URL: postgresql://docmost:docmost@localhost:5432/docmost REDIS_URL: redis://localhost:6379 @@ -123,6 +126,7 @@ jobs: # a red run plus GitHub's email to the pusher is the notification mechanism. e2e-mcp: runs-on: ubuntu-latest + timeout-minutes: 20 env: DATABASE_URL: postgresql://docmost:docmost@localhost:5432/docmost REDIS_URL: redis://localhost:6379 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 3a756656..92eea23e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -15,6 +15,7 @@ permissions: jobs: test: runs-on: ubuntu-latest + timeout-minutes: 20 # Real Postgres + Redis so the server integration suite (`*.int-spec.ts`, # behind `pnpm --filter server test:int`) runs in CI (red-team finding #7). # Without it, cost-cap / FK-cascade / jsonb-round-trip / real-apply tests