diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 01945178..7ad1e39b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,7 +33,7 @@ jobs: node: 18 host: x86 target: x86 - - os: macos-m1 + - os: macos-latest node: 18 host: arm64 target: arm64 @@ -46,15 +46,11 @@ jobs: architecture: ${{ matrix.host }} - name: Add yarn (self-hosted) - if: matrix.os == 'macos-m1' + if: matrix.os == 'macos-latest' run: npm install -g yarn - - name: Add setuptools for Python 3.12 (temp) - if: matrix.os != 'macos-m1' - run: pip install setuptools - - name: Add msbuild to PATH - uses: microsoft/setup-msbuild@v1.3 + uses: microsoft/setup-msbuild@v2 if: contains(matrix.os, 'windows') with: msbuild-architecture: ${{ matrix.target }} diff --git a/package.json b/package.json index ab413ff4..304a7d16 100644 --- a/package.json +++ b/package.json @@ -43,19 +43,22 @@ "type": "git", "url": "https://github.com/TryGhost/node-sqlite3.git" }, + "engines": { + "node": ">=18" + }, "dependencies": { "bindings": "^1.5.0", - "node-addon-api": "^7.0.0", + "node-addon-api": "^8.0.0", "prebuild-install": "^7.1.1", - "tar": "^6.1.11" + "tar": "^7.0.0" }, "devDependencies": { "eslint": "8.56.0", - "mocha": "10.2.0", - "prebuild": "12.1.0" + "mocha": "10.4.0", + "prebuild": "13.0.0" }, "peerDependencies": { - "node-gyp": "8.x" + "node-gyp": "^10.x" }, "peerDependenciesMeta": { "node-gyp": { @@ -63,7 +66,7 @@ } }, "optionalDependencies": { - "node-gyp": "8.x" + "node-gyp": "^10.x" }, "scripts": { "install": "prebuild-install -r napi || node-gyp rebuild", diff --git a/tools/BinaryBuilder.Dockerfile b/tools/BinaryBuilder.Dockerfile index 2e089b31..b9b71408 100644 --- a/tools/BinaryBuilder.Dockerfile +++ b/tools/BinaryBuilder.Dockerfile @@ -10,7 +10,8 @@ RUN if case $VARIANT in "alpine"*) true;; *) false;; esac; then apk add build-ba WORKDIR /usr/src/build COPY . . -RUN npm install --ignore-scripts + +RUN npm install --ignore-scripts --maxsockets=1 ENV CFLAGS="${CFLAGS:-} -include ../src/gcc-preinclude.h" ENV CXXFLAGS="${CXXFLAGS:-} -include ../src/gcc-preinclude.h" diff --git a/tools/semver-check.js b/tools/semver-check.js index 3b4a9a9c..3dd6c9e0 100644 --- a/tools/semver-check.js +++ b/tools/semver-check.js @@ -2,7 +2,7 @@ const fs = require('fs'); const path = require('path'); const semver = require('semver'); -const supportedVersions = '10.12.0'; +const supportedVersions = process.versions.node; function checkEngines(modulePath) { const packageJsonPath = path.join(modulePath, 'package.json'); @@ -30,4 +30,3 @@ for (const dependency of allDependencies) { const modulePath = path.join(__dirname, '..', 'node_modules', dependency); checkEngines(modulePath); } -