- Replace bcrypt (native) with bcryptjs (pure JS) — no native build on serverless - Storage abstraction (lib/storage.js): local uploads/ for traditional deploy, S3-compatible (R2/MinIO/S3 via aws4fetch) for serverless - DB pool auto-adapts to serverless (single connection, rotation, timeouts) - next.config.js: standalone output only when DOCKER=1 (serverless skips it) - Docs: serverless deployment section in README, S3 env vars in .env.example
{
|
|
"name": "forumlify",
|
|
"version": "2.0.0",
|
|
"description": "Forumlify - 简洁优雅的现代社区系统 (Next.js)",
|
|
"private": true,
|
|
"scripts": {
|
|
"dev": "next dev -H 0.0.0.0",
|
|
"build": "next build",
|
|
"start": "node scripts/start.js",
|
|
"test": "node --test --test-concurrency=1 \"test/*.test.js\""
|
|
},
|
|
"dependencies": {
|
|
"aws4fetch": "^1.0.20",
|
|
"bcryptjs": "^3.0.3",
|
|
"jsonwebtoken": "^9.0.2",
|
|
"next": "^14.2.15",
|
|
"pg": "^8.11.3",
|
|
"react": "^18.3.1",
|
|
"react-dom": "^18.3.1"
|
|
},
|
|
"devDependencies": {}
|
|
}
|