import { fileURLToPath } from 'url'; import path from 'path'; const __dirname = path.dirname(fileURLToPath(import.meta.url)); /** @type {import('next').NextConfig} */ const nextConfig = { // Explicitly set Turbopack root to this frontend directory to silence multi-lockfile warning turbopack: { root: __dirname, }, // Increase server timeout for long-running AI requests experimental: { proxyTimeout: 120000, // 120 seconds }, async rewrites() { return [ { source: "/api/:path*", destination: "http://localhost:8000/api/:path*", }, { source: "/health", destination: "http://localhost:8000/health", }, ]; }, }; export default nextConfig;