next.config.ts 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. import type { NextConfig } from "next";
  2. const nextConfig: NextConfig = {
  3. /* config options here */
  4. reactStrictMode: false,
  5. productionBrowserSourceMaps: true,
  6. // CI build does not block on lint; run `npm run lint` as a separate stage if needed.
  7. eslint: {
  8. ignoreDuringBuilds: true
  9. },
  10. images: {
  11. remotePatterns: [
  12. {
  13. protocol: "https",
  14. hostname: "localhost",
  15. port: "4000",
  16. pathname: "/uploads/**"
  17. },
  18. {
  19. protocol: "https",
  20. hostname: "api.antooza.com",
  21. pathname: "/uploads/**"
  22. },
  23. {
  24. protocol: "https",
  25. hostname: "dev-api.antooza.com",
  26. pathname: "/uploads/**"
  27. },
  28. {
  29. protocol: "https",
  30. hostname: "resource.antooza.com",
  31. pathname: "/uploads/**"
  32. },
  33. {
  34. protocol: "https",
  35. hostname: "dev-resource.antooza.com",
  36. pathname: "/uploads/**"
  37. },
  38. {
  39. protocol: "https",
  40. hostname: "img.youtube.com"
  41. },
  42. {
  43. protocol: "https",
  44. hostname: "yt3.ggpht.com"
  45. },
  46. {
  47. protocol: "https",
  48. hostname: "yt3.googleusercontent.com"
  49. }
  50. ],
  51. },
  52. experimental: {
  53. authInterrupts: true, // 인증 중단 기능 활성화
  54. serverActions: {
  55. bodySizeLimit: '200mb' // 최대 요청 본문 크기 설정
  56. }
  57. },
  58. // 배포 최적화
  59. output: 'standalone',
  60. // SVG 사용하기 위한 추가
  61. webpack(config) {
  62. config.module.rules.push({
  63. test: /\.svg$/,
  64. use: ['@svgr/webpack'],
  65. });
  66. return config;
  67. },
  68. async rewrites() {
  69. return [
  70. {
  71. source: '/uploads/:path*',
  72. destination: '/api/uploads/:path*'
  73. }
  74. ];
  75. },
  76. async redirects() {
  77. return [
  78. {
  79. source: '/docs/privacy',
  80. destination: '/docs/privacy-policy',
  81. permanent: true
  82. },
  83. {
  84. source: '/docs/terms',
  85. destination: '/docs/terms-of-service',
  86. permanent: true
  87. }
  88. ];
  89. }
  90. };
  91. export default nextConfig;