fix(reboot): harden public maintenance fallback
All checks were successful
CD Pipeline / workflow-shape (push) Successful in 0s
CD Pipeline / cancel-stale-cd (push) Has been skipped
CD Pipeline / tests (push) Successful in 58s
CD Pipeline / build-and-deploy (push) Successful in 4m27s
CD Pipeline / post-deploy-checks (push) Successful in 1m44s
All checks were successful
CD Pipeline / workflow-shape (push) Successful in 0s
CD Pipeline / cancel-stale-cd (push) Has been skipped
CD Pipeline / tests (push) Successful in 58s
CD Pipeline / build-and-deploy (push) Successful in 4m27s
CD Pipeline / post-deploy-checks (push) Successful in 1m44s
This commit is contained in:
@@ -52,6 +52,8 @@ server {
|
||||
# ============================================
|
||||
location ~ ^/api/v1/(agent|dashboard)/stream {
|
||||
proxy_pass http://awoooi_prod_api;
|
||||
proxy_intercept_errors on;
|
||||
error_page 502 503 504 =503 /__awoooi-maintenance.html;
|
||||
|
||||
# 禁用緩衝 (AI 打字機效果零延遲)
|
||||
proxy_buffering off;
|
||||
@@ -77,6 +79,8 @@ server {
|
||||
# ============================================
|
||||
location /api/sentry-tunnel {
|
||||
proxy_pass http://awoooi_prod_web;
|
||||
proxy_intercept_errors on;
|
||||
error_page 502 503 504 =503 /__awoooi-maintenance.html;
|
||||
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Connection "keep-alive";
|
||||
@@ -89,6 +93,8 @@ server {
|
||||
# ============================================
|
||||
location /api/ {
|
||||
proxy_pass http://awoooi_prod_api;
|
||||
proxy_intercept_errors on;
|
||||
error_page 502 503 504 =503 /__awoooi-maintenance.html;
|
||||
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Connection "keep-alive";
|
||||
@@ -102,6 +108,8 @@ server {
|
||||
# ============================================
|
||||
location /api/health {
|
||||
proxy_pass http://awoooi_prod_api/health;
|
||||
proxy_intercept_errors on;
|
||||
error_page 502 503 504 =503 /__awoooi-maintenance.html;
|
||||
proxy_read_timeout 5s;
|
||||
|
||||
# 允許監控系統存取
|
||||
@@ -114,6 +122,8 @@ server {
|
||||
# ============================================
|
||||
location / {
|
||||
proxy_pass http://awoooi_prod_web;
|
||||
proxy_intercept_errors on;
|
||||
error_page 502 503 504 =503 /__awoooi-maintenance.html;
|
||||
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
@@ -122,6 +132,8 @@ server {
|
||||
# 靜態資源快取
|
||||
location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg|woff|woff2)$ {
|
||||
proxy_pass http://awoooi_prod_web;
|
||||
proxy_intercept_errors on;
|
||||
error_page 502 503 504 =503 /__awoooi-maintenance.html;
|
||||
expires 7d;
|
||||
add_header Cache-Control "public, immutable";
|
||||
}
|
||||
@@ -130,7 +142,7 @@ server {
|
||||
# ============================================
|
||||
# Public maintenance fallback
|
||||
# ============================================
|
||||
error_page 502 503 504 /__awoooi-maintenance.html;
|
||||
error_page 502 503 504 =503 /__awoooi-maintenance.html;
|
||||
location = /__awoooi-maintenance.html {
|
||||
internal;
|
||||
root /var/www/maintenance;
|
||||
|
||||
Reference in New Issue
Block a user