using pnpm for ci/cd
Some checks failed
Build and Deploy DAVE | DMG / deploy (push) Failing after 5s

This commit is contained in:
2025-09-15 10:51:20 +02:00
parent f38148e191
commit 864037a6e9

View File

@@ -1,4 +1,4 @@
name: Build and Deploy Next.js Site name: Build and Deploy DAVE | DMG
on: on:
push: push:
@@ -16,27 +16,28 @@ jobs:
uses: actions/setup-node@v4 uses: actions/setup-node@v4
with: with:
node-version: '18' node-version: '18'
cache: 'npm' cache: 'pnpm'
- name: Cache Next.js build - name: Install pnpm
run: npm install -g pnpm
- name: Cache pnpm store
uses: actions/cache@v4 uses: actions/cache@v4
with: with:
path: | path: ~/.pnpm-store
~/.npm key: ${{ runner.os }}-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
${{ github.workspace }}/.next/cache
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}-${{ hashFiles('**/*.js', '**/*.jsx', '**/*.ts', '**/*.tsx') }}
restore-keys: | restore-keys: |
${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}- ${{ runner.os }}-pnpm-
- name: Disable Next.js telemetry - name: Disable Next.js telemetry
run: npx next telemetry disable run: npx next telemetry disable
- name: Install dependencies - name: Install dependencies
run: npm ci run: pnpm install --frozen-lockfile
- name: Build and deploy - name: Build and deploy
run: | run: |
mv src/app/\(cms\) src/app/_cms mv src/app/\(cms\) src/app/_cms
npm run build pnpm run build
rm -rf /var/www/sites/dave-dmg/blog/* rm -rf /var/www/sites/dave-dmg/blog/*
cp -r out/* /var/www/sites/dave-dmg/blog/ cp -r out/* /var/www/sites/dave-dmg/blog/