/** @type {import('next').NextConfig} */ const nextConfig = { // Configuración para proxy reverso (nginx) async headers() { return [ { source: '/api/:path*', headers: [ { key: 'X-Forwarded-Proto', value: 'https', }, ], }, ]; }, // Configuración experimental para mejorar el manejo de headers experimental: { serverComponentsExternalPackages: ['ping'], }, // Configuración de red env: { TRUST_PROXY: 'true', }, }; export default nextConfig;