Files
jotion/nextjs/next.config.mjs
Mayne0213 e82ea71c22 REFACTOR(repo): simplify project structure
- Move services/nextjs to nextjs/
- Move deploy/docker/Dockerfile.prod to Dockerfile
- Add GitHub Actions workflows (ci.yml, build.yml)
- Remove deploy/, services/, scripts/ folders
2026-01-05 02:29:10 +09:00

48 lines
872 B
JavaScript

/** @type {import('next').NextConfig} */
const nextConfig = {
// Enable standalone output for Docker
output: 'standalone',
// Optimize for Docker
outputFileTracingRoot: '/app',
// Image optimization
images: {
remotePatterns: [
{
protocol: 'https',
hostname: '**',
},
],
},
// API configuration
async headers() {
return [
{
source: '/api/:path*',
headers: [
{
key: 'Cache-Control',
value: 'no-store, max-age=0',
},
],
},
];
},
// Webpack configuration for Docker
webpack: (config, { isServer }) => {
if (!isServer) {
config.resolve.fallback = {
...config.resolve.fallback,
fs: false,
net: false,
tls: false,
};
}
return config;
},
};
export default nextConfig;