chore(deps): risolve vulnerabilità npm audit e aggiorna a Node 24 LTS

Aggiorna vitest/@vitest/ui alla 4.1.10 (azzera le 14 vulnerabilità
segnalate da npm audit, incluse 2 critiche). Node 20 era ormai a fine
supporto: Dockerfile, .nvmrc ed engines in package.json passano a
Node 24 LTS; il README documenta i requisiti in una sezione dedicata
in cima al file, senza duplicarli altrove.
This commit is contained in:
2026-07-15 10:58:41 +02:00
parent 93372a1299
commit bd90a2efe4
5 changed files with 450 additions and 396 deletions
+1
View File
@@ -0,0 +1 @@
24
+2 -2
View File
@@ -1,5 +1,5 @@
# Stage 1: dipendenze condivise (build + dev)
FROM node:20-alpine AS deps
FROM node:24-alpine AS deps
WORKDIR /app
COPY package*.json ./
RUN npm ci
@@ -16,7 +16,7 @@ COPY . .
RUN npm run build
# Stage 4: runtime di produzione
FROM node:20-alpine AS runtime
FROM node:24-alpine AS runtime
WORKDIR /app
ENV NODE_ENV=production PORT=3000
+16 -10
View File
@@ -1,7 +1,7 @@
# Segnapunti
![Version](https://img.shields.io/badge/versione-2.1.0-blue)
![Node](https://img.shields.io/badge/node-%3E%3D18-green)
![Node](https://img.shields.io/badge/node-%3E%3D24-green)
![Docker](https://img.shields.io/badge/docker-ready-2496ED?logo=docker&logoColor=white)
![License](https://img.shields.io/badge/licenza-privata-lightgrey)
@@ -9,8 +9,21 @@ Segnapunti digitale in tempo reale per partite di pallavolo. Un server centrale
---
## Requisiti
| Strumento | Versione minima | Uso |
|---|---|---|
| Node.js | >= 24 | Sviluppo locale (`npm run dev`) |
| npm | >= 11 | Sviluppo locale |
| Docker + Docker Compose | — | Deploy in produzione; alternativa containerizzata allo sviluppo locale |
Versione Node pinnata in `.nvmrc` e in `engines` di `package.json`. Con [nvm](https://github.com/nvm-sh/nvm): `nvm use`.
---
## Indice
- [Requisiti](#requisiti)
- [Architettura](#architettura)
- [Guida utente](#guida-utente)
- [Funzionalità](#funzionalità)
@@ -18,6 +31,7 @@ Segnapunti digitale in tempo reale per partite di pallavolo. Un server centrale
- [Sviluppo](#sviluppo)
- [Sviluppo con Docker](#sviluppo-con-docker)
- [Test](#test)
- [Changelog](#changelog)
---
@@ -166,7 +180,6 @@ La **partita** è vinta da chi raggiunge 3 set su 5 (modalità `3/5`) o 2 set su
---
## Deploy con Docker
### Prima installazione
@@ -209,13 +222,6 @@ docker run --rm -p 3000:3000 -v ./.segnapunti:/app/.segnapunti segnapunti:local
## Sviluppo
### Requisiti
| Strumento | Versione minima |
|---|---|
| Node.js | >= 18 |
| npm | >= 9 |
### Avvio
```bash
@@ -253,7 +259,7 @@ docker compose -f docker-compose.dev.yml up --build
| `http://localhost:5173/display` | Display |
| `http://localhost:5173/controller` | Controller |
Le modifiche ai file sorgente sull'host si riflettono subito nel container (bind-mount); `node_modules` resta invece un volume anonimo del container, per non farsi sovrascrivere dal bind-mount e per evitare incompatibilità tra i binari nativi installati sull'host e quelli richiesti dal container (es. host ARM / container `node:20-alpine` su x86).
Le modifiche ai file sorgente sull'host si riflettono subito nel container (bind-mount); `node_modules` resta invece un volume anonimo del container, per non farsi sovrascrivere dal bind-mount e per evitare incompatibilità tra i binari nativi installati sull'host e quelli richiesti dal container (es. host ARM / container `node:24-alpine` su x86).
Per fermare e rimuovere il container:
+426 -382
View File
File diff suppressed because it is too large Load Diff
+5 -2
View File
@@ -3,6 +3,9 @@
"private": true,
"version": "2.1.0",
"type": "module",
"engines": {
"node": ">=24.0.0"
},
"scripts": {
"dev": "vite --host",
"build": "vite build",
@@ -30,12 +33,12 @@
"@playwright/test": "^1.58.2",
"@types/node": "^25.2.3",
"@vitejs/plugin-vue": "^6.0.5",
"@vitest/ui": "^4.0.18",
"@vitest/ui": "^4.1.10",
"@vue/test-utils": "^2.4.6",
"happy-dom": "^20.6.1",
"jsdom": "^28.0.0",
"vite": "^7.3.1",
"vite-plugin-pwa": "^1.2.0",
"vitest": "^4.0.18"
"vitest": "^4.1.10"
}
}