Files
kspguti-schedule/next.config.js
kilyabin fa7fd147f5 fix: исправить загрузку статических файлов в продакшене
- Убран outputFileTracingRoot из next.config.js для корректной работы standalone режима
- В install.sh добавлено удаление старых файлов перед копированием новых
- Статические файлы (.next/static) и public теперь копируются корректно

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-03-05 14:04:43 +04:00

26 lines
806 B
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: true,
output: 'standalone',
generateEtags: false,
allowedDevOrigins: ['192.168.1.10'],
// Не используем outputFileTracingRoot для корректной работы standalone режима
webpack: (config, { isServer }) => {
// Исключаем fs и path из клиентской сборки
if (!isServer) {
config.resolve.fallback = {
...config.resolve.fallback,
fs: false,
path: false,
}
}
return config
},
// Указываем корневую директорию для устранения предупреждения о множественных lockfiles
turbopack: {
root: __dirname,
},
}
module.exports = nextConfig