From 8a8b3268b4cab5387942af82bb8e4db1e21a4774 Mon Sep 17 00:00:00 2001 From: Johannes Kettmann Date: Fri, 27 Sep 2024 10:25:20 +0200 Subject: [PATCH] Fix GitHub Actions --- .github/workflows/main.yml | 46 +++++++++++--------------------------- 1 file changed, 13 insertions(+), 33 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 1cbd3d7..2cbf134 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -7,26 +7,14 @@ on: branches: [main] jobs: - install: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: "18" - cache: "npm" - - run: npm ci - lint: runs-on: ubuntu-latest - needs: install steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: "18" + node-version: "20" cache: "npm" - run: npm ci - run: npm run lint:code @@ -36,40 +24,32 @@ jobs: build: runs-on: ubuntu-latest - needs: install env: NEXT_PUBLIC_API_BASE_URL: ${{vars.NEXT_PUBLIC_API_BASE_URL}} steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: "18" + node-version: "20" cache: "npm" - run: npm ci - run: npm run build - - name: Archive production artifacts - uses: actions/upload-artifact@v3 - with: - name: nextjs-build - path: .next/ e2e: runs-on: ubuntu-latest - needs: build + env: + NEXT_PUBLIC_API_BASE_URL: ${{vars.NEXT_PUBLIC_API_BASE_URL}} steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: "18" + node-version: "20" cache: "npm" - run: npm ci - - name: Download build artifacts - uses: actions/download-artifact@v3 - with: - name: nextjs-build - path: .next/ + - name: Build app + run: npm run build - name: Cypress run uses: cypress-io/github-action@v4 with: