Files
gooseek/backend/webui/next.config.mjs
home 32102c379a
Some checks failed
Build and Deploy GooSeek / build-and-deploy (push) Has been cancelled
fix: restore deployment — ingress routing, readiness probes, rate limiter
- Ingress: route /api/* on gooseek.ru to api-gateway (was going to webui)
- api-gateway: move /health and /ready before JWT/rate-limit middleware
  to prevent liveness probe 429 failures causing CrashLoopBackOff
- Readiness probes: fix agent-svc, search-svc, scraper-svc to use /health
  (they don't implement /ready endpoint, causing permanent 0/1 status)
- ConfigMap: add missing CHAT_SVC_URL and API_GATEWAY_URL
- deploy.sh: also clean up misplaced NetworkPolicy from gooseek namespace
- webui: add Next.js rewrites to proxy /api/* to api-gateway

Made-with: Cursor
2026-03-03 04:10:41 +03:00

23 lines
614 B
JavaScript

/** @type {import('next').NextConfig} */
const API_GATEWAY = process.env.API_GATEWAY_URL || process.env.API_URL || 'http://api-gateway:3015';
const nextConfig = {
output: 'standalone',
reactStrictMode: true,
env: {
API_URL: API_GATEWAY,
NEXT_PUBLIC_TWOGIS_API_KEY: process.env.NEXT_PUBLIC_TWOGIS_API_KEY || process.env.TWOGIS_API_KEY || '',
NEXT_PUBLIC_ENABLED_ROUTES: process.env.NEXT_PUBLIC_ENABLED_ROUTES || '',
},
async rewrites() {
return [
{
source: '/api/:path*',
destination: `${API_GATEWAY}/api/:path*`,
},
];
},
};
export default nextConfig;