chore(ci): Optimize Turborepo cache restoring and add Next.js BuildKit caching
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 29s
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / ♿ WCAG (push) Has been cancelled
Build & Deploy / 🛡️ Quality Gates (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled
Build & Deploy / 🧪 QA (push) Successful in 1m45s
Build & Deploy / 🏗️ Build (push) Has been cancelled

This commit is contained in:
2026-02-23 02:17:31 +01:00
parent 9694c77ef7
commit 63853ffa89
4 changed files with 15 additions and 6 deletions

View File

@@ -50,12 +50,15 @@ jobs:
uses: actions/cache@v4
with:
path: .turbo
key: ${{ runner.os }}-turbo-${{ github.sha }}
key: ${{ runner.os }}-turbo-${{ github.ref_name }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-turbo-${{ github.ref_name }}-
${{ runner.os }}-turbo-
- name: 🧪 QA Checks
run: npx turbo run check:mdx lint typecheck test
env:
TURBO_TELEMETRY_DISABLED: 1
run: npx turbo run check:mdx lint typecheck test --cache-dir=".turbo"
- name: 🏗️ Build
run: pnpm build

View File

@@ -175,15 +175,18 @@ jobs:
uses: actions/cache@v4
with:
path: .turbo
key: ${{ runner.os }}-turbo-${{ github.sha }}
key: ${{ runner.os }}-turbo-${{ github.ref_name }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-turbo-${{ github.ref_name }}-
${{ runner.os }}-turbo-
- name: 🔒 Security Audit
run: pnpm audit --audit-level high
- name: 🧪 QA Checks
if: github.event.inputs.skip_checks != 'true'
run: npx turbo run lint check:spell typecheck test
env:
TURBO_TELEMETRY_DISABLED: 1
run: npx turbo run lint check:spell typecheck test --cache-dir=".turbo"
# ──────────────────────────────────────────────────────────────────────────────
# JOB 3: Build & Push
@@ -209,6 +212,8 @@ jobs:
push: true
provenance: false
platforms: linux/arm64
cache-from: type=gha,scope=nextjs-build-${{ needs.prepare.outputs.target }}
cache-to: type=gha,mode=max,scope=nextjs-build-${{ needs.prepare.outputs.target }}
build-args: |
NEXT_PUBLIC_BASE_URL=${{ needs.prepare.outputs.next_public_url }}
NEXT_PUBLIC_TARGET=${{ needs.prepare.outputs.target }}