Set outputFileTracingRoot back to projectRoot. In Docker, the parent (monorepoRoot) was /, which caused Next.js to emit server.js at .next/standalone/app/server.js and pull in /usr, /root, /proc paths, breaking from /app. Fixes #1064 Co-authored-by: Muhammad Ridwan Ramadhan <ridwanramadhan8888@gmail.com>
This commit is contained in:
parent
74c9879e8e
commit
692d1fdf57
1 changed files with 3 additions and 4 deletions
|
|
@ -1,8 +1,7 @@
|
|||
import { fileURLToPath } from "node:url";
|
||||
import { dirname, resolve } from "node:path";
|
||||
import { dirname } from "node:path";
|
||||
|
||||
const projectRoot = dirname(fileURLToPath(import.meta.url));
|
||||
const monorepoRoot = resolve(projectRoot, "..");
|
||||
|
||||
/** @type {import('next').NextConfig} */
|
||||
const nextConfig = {
|
||||
|
|
@ -11,9 +10,9 @@ const nextConfig = {
|
|||
turbopack: {
|
||||
root: projectRoot
|
||||
},
|
||||
outputFileTracingRoot: monorepoRoot,
|
||||
outputFileTracingRoot: projectRoot,
|
||||
outputFileTracingExcludes: {
|
||||
"*": ["./app/gitbook/**/*", "./gitbook/**/*"]
|
||||
"*": ["./gitbook/**/*"]
|
||||
},
|
||||
images: {
|
||||
unoptimized: true
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue