diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml new file mode 100644 index 0000000..f1ac5bb --- /dev/null +++ b/.gitea/workflows/deploy.yml @@ -0,0 +1,31 @@ +# Push sur main → vérification, build, audit Lighthouse (scores >= 90), déploiement. +# Runner : gitea-runner en mode host sur le VPS1 (label vps1), voir vps1-quadlets. +name: Portfolio + +on: + push: + branches: [main] + workflow_dispatch: + +jobs: + build-deploy: + runs-on: vps1 + steps: + - uses: actions/checkout@v4 + + - name: Dépendances + run: pnpm install --frozen-lockfile + + - name: Vérification + run: pnpm check + + - name: Build + run: pnpm build + + - name: Lighthouse (scores >= 90) + run: pnpm lighthouse + + - name: Déploiement + run: | + test -f dist/index.html + rsync -a --delete dist/ /deploy/portfolio/