From 0c836b49cd0c4b1a7cda807ccb5b1f8005202f9f Mon Sep 17 00:00:00 2001 From: stabgan Date: Thu, 27 Mar 2025 01:01:58 +0530 Subject: [PATCH] Update Node.js to v20 and upgrade GitHub Actions --- .github/workflows/publish.yml | 22 ++++++++++++++++------ Dockerfile | 2 +- 2 files changed, 17 insertions(+), 7 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 0eef4ff..0f61b24 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -18,12 +18,17 @@ jobs: - name: Set up Node.js uses: actions/setup-node@v4 with: - node-version: '18' + node-version: '20' cache: 'npm' cache-dependency-path: package-lock.json + - name: Verify Node.js and npm versions + run: | + node --version + npm --version + - name: Cache dependencies - uses: actions/cache@v3 + uses: actions/cache@v4 id: npm-cache with: path: | @@ -45,7 +50,7 @@ jobs: run: npm cache clean --force && npm install --legacy-peer-deps --no-optional - name: Cache build output - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: dist key: ${{ runner.os }}-build-${{ github.sha }} @@ -76,13 +81,18 @@ jobs: - name: Set up Node.js uses: actions/setup-node@v4 with: - node-version: '18' + node-version: '20' registry-url: 'https://registry.npmjs.org' cache: 'npm' cache-dependency-path: package-lock.json + - name: Verify Node.js and npm versions + run: | + node --version + npm --version + - name: Cache dependencies - uses: actions/cache@v3 + uses: actions/cache@v4 id: npm-cache with: path: | @@ -131,7 +141,7 @@ jobs: uses: docker/setup-buildx-action@v3 - name: Cache Docker layers - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: /tmp/.buildx-cache key: ${{ runner.os }}-buildx-${{ github.sha }} diff --git a/Dockerfile b/Dockerfile index 9e460d3..76e21b4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM node:18-alpine +FROM node:20-alpine WORKDIR /app