Files
tuxmate/next.config.ts
NIJAT 9930abd991 fix: support both static export (CF Pages) and standalone (Docker) builds
- next.config.ts now checks STATIC_EXPORT env var to toggle output mode
- Added pages:build script for Cloudflare Pages to use
- Docker uses default 'npm run build' which creates .next/standalone
- CF Pages should use 'npm run pages:build' which creates out/
2025-12-29 18:34:48 +04:00

12 lines
305 B
TypeScript

import type { NextConfig } from "next";
const nextConfig: NextConfig = {
// Use 'export' for static hosting (CF Pages), 'standalone' for Docker/self-hosting
output: process.env.STATIC_EXPORT === 'true' ? 'export' : 'standalone',
images: {
unoptimized: true,
},
};
export default nextConfig;