high95%
next dev overrides container-aware V8 heap limit using host memory
Next.js dev server calculates the V8 max-old-space-size based on host total memory (os.totalmem()), ignoring container memory constraints. In a Docker container with a memory limit, this sets an excessively high heap limit, potentially leading to out-of-memory (OOM) kills or performance degradation. Node.js already provides process.constrainedMemory() which respects cgroup limits; Next.js should use it when available.
