fix(nginx): Route /api/sentry-tunnel to Next.js frontend
Sentry Tunnel is a Next.js API Route, not FastAPI endpoint. Must be handled by frontend server to avoid 404. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -68,7 +68,20 @@ server {
|
||||
}
|
||||
|
||||
# ============================================
|
||||
# 一般 API 路由
|
||||
# Next.js API Routes (前端處理)
|
||||
# ⚠️ 必須在 /api/ 之前,否則會被後端攔截
|
||||
# ============================================
|
||||
location /api/sentry-tunnel {
|
||||
proxy_pass http://awoooi_prod_web;
|
||||
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Connection "keep-alive";
|
||||
proxy_read_timeout 30s;
|
||||
proxy_send_timeout 30s;
|
||||
}
|
||||
|
||||
# ============================================
|
||||
# 一般 API 路由 (FastAPI 後端)
|
||||
# ============================================
|
||||
location /api/ {
|
||||
proxy_pass http://awoooi_prod_api;
|
||||
|
||||
Reference in New Issue
Block a user