From b5b95ae5e147fa33be0b8bc1b998c71f82470ba1 Mon Sep 17 00:00:00 2001 From: Jeff Emmett Date: Wed, 1 Apr 2026 00:20:41 -0700 Subject: [PATCH] CI: merge test + build into single job to avoid double npm ci Running npm ci twice in separate containers causes OOM on the shared host. Single job: npm ci once, then tsc, vitest, and vite build in sequence. Co-Authored-By: Claude Opus 4.6 --- .gitea/workflows/ci.yml | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 6c1770d..410e5e8 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -12,7 +12,7 @@ env: IMAGE: gitea.jeffemmett.com/jeffemmett/canvas-website jobs: - test: + test-and-build: runs-on: ubuntu-latest steps: - name: Checkout @@ -34,27 +34,14 @@ jobs: - name: Worker tests run: npx vitest run --config vitest.worker.config.ts || echo "::warning::Worker tests had failures" - build-check: - runs-on: ubuntu-latest - steps: - - name: Checkout - run: | - apt-get update -qq && apt-get install -y -qq git > /dev/null 2>&1 - git clone --depth 1 --branch ${{ github.ref_name }} http://token:${{ github.token }}@server:3000/${{ github.repository }}.git . - - - name: Install dependencies - run: npm ci --legacy-peer-deps --ignore-scripts - env: - NODE_OPTIONS: "--max-old-space-size=4096" - - name: Build - run: npx tsc && npx vite build + run: npx vite build env: NODE_OPTIONS: "--max-old-space-size=4096" deploy: if: github.ref == 'refs/heads/main' && github.event_name == 'push' - needs: [test, build-check] + needs: [test-and-build] runs-on: ubuntu-latest container: image: docker:24-cli