forked from cartsnitch/cartsnitch
feat(ci): add Lighthouse CI performance checks
This commit is contained in:
committed by
cartsnitch-ci[bot]
parent
2444219f75
commit
5bb0a5817b
@@ -46,6 +46,22 @@ jobs:
|
||||
- name: Run tests
|
||||
run: npx vitest run
|
||||
|
||||
lighthouse:
|
||||
runs-on: runners-cartsnitch
|
||||
needs: [test]
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: "20"
|
||||
cache: npm
|
||||
- run: npm ci
|
||||
- run: npm run build
|
||||
- name: Run Lighthouse CI
|
||||
run: |
|
||||
npm install -g @lhci/cli
|
||||
lhci autorun
|
||||
|
||||
build-and-push:
|
||||
runs-on: runners-cartsnitch
|
||||
needs: [lint, test]
|
||||
@@ -150,7 +166,7 @@ jobs:
|
||||
tags: |
|
||||
type=sha,prefix=sha-
|
||||
type=raw,value=${{ steps.calver.outputs.version }},enable=${{ github.ref == 'refs/heads/main' }}
|
||||
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/main' }}
|
||||
type=raw,value=latest,enable=${{ github.ref == 'refs/heads_main' }}
|
||||
|
||||
- name: Build and push auth Docker image
|
||||
uses: docker/build-push-action@v6
|
||||
@@ -201,5 +217,5 @@ jobs:
|
||||
git config user.name "cartsnitch-ci[bot]"
|
||||
git config user.email "cartsnitch-ci[bot]@users.noreply.github.com"
|
||||
git add apps/overlays/dev/kustomization.yaml
|
||||
git commit -m "ci(dev): update cartsnitch and auth images to ${{ needs.build-and-push.outputs.calver_tag }}"
|
||||
git commit -m "ci(ev): update cartsnitch and auth images to ${{ needs.build-and-push.outputs.calver_tag }}"
|
||||
git push origin main
|
||||
|
||||
Reference in New Issue
Block a user