diff --git a/Dockerfile b/Dockerfile index 84b6df3..4fa6676 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,7 @@ COPY --from=deps /app/node_modules ./node_modules COPY . . # 禁用 Next.js 遥测,并注入占位环境变量以通过编译 ENV NEXT_TELEMETRY_DISABLED=1 -RUN npm run build +RUN npm run build -- --no-turbopack # 阶段 3:生产运行环境 FROM node:20-alpine AS runner diff --git a/next.config.ts b/next.config.ts index 0ae7d0f..3270180 100644 --- a/next.config.ts +++ b/next.config.ts @@ -10,10 +10,14 @@ const nextConfig: NextConfig = { ignoreBuildErrors: true, }, + experimental: { + turbo: { + resolveExtensions: ['.tsx', '.ts', '.jsx', '.js'], + }, + }, + allowedDevOrigins: [ - '10.10.10.1', // 允许该IP访问 - // 'your-custom-domain.dev', // 如果有自定义域名也可以加在这里 - // '*.local-origin.dev' // 支持通配符 + '10.10.10.1', ], };