diff --git a/.github/workflows/component-tests.yml b/.github/workflows/component-tests.yml index fcc2c2138..b59001812 100644 --- a/.github/workflows/component-tests.yml +++ b/.github/workflows/component-tests.yml @@ -34,7 +34,7 @@ jobs: - name: Set up Node.js uses: actions/setup-node@v4 with: - node-version: 20 + node-version: 24 cache: 'npm' - name: Install dependencies diff --git a/.github/workflows/i18n-integration.yml b/.github/workflows/i18n-integration.yml index 8b3a4678f..e472487c5 100644 --- a/.github/workflows/i18n-integration.yml +++ b/.github/workflows/i18n-integration.yml @@ -20,7 +20,7 @@ jobs: - name: Set up node uses: actions/setup-node@v4 with: - node-version: 20 + node-version: 24 cache: 'npm' # The only argument is the `directory`, which is where the i18n files are diff --git a/.github/workflows/integration-test.yml b/.github/workflows/integration-test.yml index beadc7f28..31eada873 100644 --- a/.github/workflows/integration-test.yml +++ b/.github/workflows/integration-test.yml @@ -24,10 +24,10 @@ jobs: - name: setup node uses: actions/setup-node@v4 with: - node-version: 20 + node-version: 24 cache: 'npm' - - name: install pkg (using yao-pkg fork for targeting node20) + - name: install pkg (using yao-pkg fork for targeting node24) run: npm install -g @yao-pkg/pkg - name: get client dependencies @@ -42,7 +42,7 @@ jobs: run: npm ci && npm run build:server && npm prune --omit=dev - name: build binary - run: pkg --config package.json -t node20-linux-x64 -o audiobookshelf dist-server/index.js + run: pkg --config package.json -t node24-linux-x64 -o audiobookshelf dist-server/index.js - name: run audiobookshelf run: | diff --git a/.github/workflows/lint-openapi.yml b/.github/workflows/lint-openapi.yml index ec08ecb36..0a75f041c 100644 --- a/.github/workflows/lint-openapi.yml +++ b/.github/workflows/lint-openapi.yml @@ -23,7 +23,7 @@ jobs: - name: Set up node uses: actions/setup-node@v4 with: - node-version: 20 + node-version: 24 cache: 'npm' # Install Redocly CLI diff --git a/.github/workflows/unit-tests.yml b/.github/workflows/unit-tests.yml index 9eb5cc0a3..ada128d1e 100644 --- a/.github/workflows/unit-tests.yml +++ b/.github/workflows/unit-tests.yml @@ -28,7 +28,7 @@ jobs: - name: Set up Node.js uses: actions/setup-node@v4 with: - node-version: 20 + node-version: 24 cache: 'npm' - name: Install dependencies diff --git a/Dockerfile b/Dockerfile index cbb2ed53c..23a6a7bbb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ ARG NUSQLITE3_DIR="/usr/local/lib/nusqlite3" ARG NUSQLITE3_PATH="${NUSQLITE3_DIR}/libnusqlite3.so" ### STAGE 0: Build client ### -FROM node:20-alpine AS build-client +FROM node:24-alpine AS build-client WORKDIR /client COPY /client /client @@ -10,7 +10,7 @@ RUN npm ci && npm cache clean --force RUN npm run generate ### STAGE 1: Compile server on the builder CPU (avoid QEMU SIGILL from tsc on arm64) ### -FROM --platform=$BUILDPLATFORM node:20-alpine AS compile-server +FROM --platform=$BUILDPLATFORM node:24-alpine AS compile-server WORKDIR /server COPY index.js package* tsconfig.server.json /server @@ -18,7 +18,7 @@ COPY /server /server/server RUN npm ci --include=dev --ignore-scripts && npm run build:server ### STAGE 2: Install native server deps for the target arch ### -FROM node:20-alpine AS build-server +FROM node:24-alpine AS build-server ARG NUSQLITE3_DIR ARG TARGETPLATFORM @@ -50,7 +50,7 @@ RUN case "$TARGETPLATFORM" in \ RUN npm ci --omit=dev ### STAGE 3: Create minimal runtime image ### -FROM node:20-alpine +FROM node:24-alpine ARG NUSQLITE3_DIR ARG NUSQLITE3_PATH diff --git a/build/linuxpackager b/build/linuxpackager index ddd53476e..501d83913 100755 --- a/build/linuxpackager +++ b/build/linuxpackager @@ -49,7 +49,7 @@ Description: $DESCRIPTION" echo "$controlfile" > dist/debian/DEBIAN/control; # Package debian -pkg --config package.json -t node20-linux-x64 -o dist/debian/usr/share/audiobookshelf/audiobookshelf dist-server/index.js +pkg --config package.json -t node24-linux-x64 -o dist/debian/usr/share/audiobookshelf/audiobookshelf dist-server/index.js fakeroot dpkg-deb -Zxz --build dist/debian diff --git a/client/nuxt.config.js b/client/nuxt.config.js index 7219c7847..65b0b3e47 100644 --- a/client/nuxt.config.js +++ b/client/nuxt.config.js @@ -60,6 +60,7 @@ module.exports = { proxy, io: { + server: false, sockets: [ { name: 'dev', diff --git a/package-lock.json b/package-lock.json index e2b990a43..1c4a4630e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -34,7 +34,7 @@ "audiobookshelf": "dist-server/index.js" }, "devDependencies": { - "@types/node": "^20.17.0", + "@types/node": "^24.13.6", "chai": "^4.3.10", "eslint": "^10.11.0", "mocha": "^10.2.0", @@ -1016,12 +1016,12 @@ "integrity": "sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA==" }, "node_modules/@types/node": { - "version": "20.19.43", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.43.tgz", - "integrity": "sha512-6oYBAi5ikg4Pl+kGsoYtawUMBT2zZMCvPNF7pVLnHZfd1zf38DRiWn/gT01RYCdUqkv7Fhr+C9ot4/tb+2sVvA==", + "version": "24.13.6", + "resolved": "https://registry.npmjs.org/@types/node/-/node-24.13.6.tgz", + "integrity": "sha512-SGrw/h3KPFshy3OE6ZL53LMBG5vGQQ8/gIpiqz/kRZhPJ7HgwCEs8LBuNtWLa8dvGZVpSF7+Bf+c11HUrCb/yg==", "license": "MIT", "dependencies": { - "undici-types": "~6.21.0" + "undici-types": "~7.18.0" } }, "node_modules/@types/validator": { @@ -6162,9 +6162,9 @@ "dev": true }, "node_modules/undici-types": { - "version": "6.21.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", - "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", + "version": "7.18.2", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.18.2.tgz", + "integrity": "sha512-AsuCzffGHJybSaRrmr5eHr81mwJU3kjw6M+uprWvCXiNeN9SOGwQ3Jn8jb8m3Z6izVgknn1R0FTCEAP2QrLY/w==", "license": "MIT" }, "node_modules/unique-filename": { diff --git a/package.json b/package.json index d8309c5b4..cd32a2034 100644 --- a/package.json +++ b/package.json @@ -11,8 +11,8 @@ "start-dev": "node dist-server/index.js --prod-with-dev-env", "client": "cd client && npm ci && npm run generate", "prod": "npm run client && npm ci && npm run build:server && npm run start", - "build-win": "npm run client && npm run build:server && pkg --config package.json -t node20-win-x64 -o ./dist/win/audiobookshelf -C GZip dist-server/index.js", - "build-win-no-compress": "npm run client && npm run build:server && pkg --config package.json -t node20-win-x64 -o ./dist/win/audiobookshelf dist-server/index.js", + "build-win": "npm run client && npm run build:server && pkg --config package.json -t node24-win-x64 -o ./dist/win/audiobookshelf -C GZip dist-server/index.js", + "build-win-no-compress": "npm run client && npm run build:server && pkg --config package.json -t node24-win-x64 -o ./dist/win/audiobookshelf dist-server/index.js", "build-linux": "build/linuxpackager", "docker": "docker buildx build --platform linux/amd64,linux/arm64 --push . -t advplyr/audiobookshelf", "docker-amd64-local": "docker buildx build --platform linux/amd64 --load . -t advplyr/audiobookshelf-amd64-local", @@ -62,7 +62,7 @@ "xml2js": "^0.5.0" }, "devDependencies": { - "@types/node": "^20.17.0", + "@types/node": "^24.13.6", "chai": "^4.3.10", "eslint": "^10.11.0", "mocha": "^10.2.0", diff --git a/readme.md b/readme.md index 00ae8ea1f..bcbdb7917 100644 --- a/readme.md +++ b/readme.md @@ -165,7 +165,7 @@ You are now ready to start development! ### Manual Environment Setup -If you don't want to use the dev container, you can still develop this project. First, you will need to install [NodeJs](https://nodejs.org/) (version 20) and [FFmpeg](https://ffmpeg.org/). +If you don't want to use the dev container, you can still develop this project. First, you will need to install [NodeJs](https://nodejs.org/) (version 24) and [FFmpeg](https://ffmpeg.org/). Next you will need to create a `dev.js` file in the project's root directory. This contains configuration information and paths unique to your development environment. You can find an example of this file in `.devcontainer/dev.js`.