From e245c8af4561492e192f05f712f76a3367dcd134 Mon Sep 17 00:00:00 2001 From: Steven Date: Sat, 18 Jul 2026 03:13:19 +1000 Subject: [PATCH] fix(frontend): scope Turbopack to the app directory Set turbopack.root explicitly to prevent Next.js from inferring the repository root from multiple lockfiles, reducing unnecessary file watching and dev cache growth. --- frontend/next.config.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/frontend/next.config.ts b/frontend/next.config.ts index 2338710..3eeaf88 100644 --- a/frontend/next.config.ts +++ b/frontend/next.config.ts @@ -9,7 +9,12 @@ const nextConfig: NextConfig = { // package-lock.json makes Next infer the repo root as the tracing root and // nest the standalone output under frontend/, breaking the Dockerfile CMD. outputFileTracingRoot: path.join(__dirname), + turbopack: { + root: path.resolve(__dirname), + }, + serverExternalPackages: ["mongodb", "pino", "pino-pretty"], + }; export default nextConfig;