From c065eddff159c9d430694dc7af9f0cbed3a6a2ef Mon Sep 17 00:00:00 2001 From: jxxghp Date: Sat, 20 Jun 2026 14:59:56 +0800 Subject: [PATCH] fix(nginx): suppress error logs for specific locations in nginx configuration --- docker/nginx.common.conf | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docker/nginx.common.conf b/docker/nginx.common.conf index 21d70611..faf6f793 100644 --- a/docker/nginx.common.conf +++ b/docker/nginx.common.conf @@ -11,6 +11,8 @@ location / { # 本地CookieCloud location /cookiecloud { + error_log /dev/null crit; + proxy_pass http://backend_api; rewrite ^.+mock-server/?(?.*)$ /$suffix break; proxy_http_version 1.1; @@ -30,6 +32,8 @@ location /cookiecloud { # SSE特殊配置 location ~ ^/api/v1/(system/(message|progress/|logging)|search/.*/stream$) { + error_log /dev/null crit; + # SSE MIME类型设置 default_type text/event-stream; @@ -53,6 +57,8 @@ location ~ ^/api/v1/(system/(message|progress/|logging)|search/.*/stream$) { # API代理配置 location /api { + error_log /dev/null crit; + proxy_pass http://backend_api; rewrite ^.+mock-server/?(?.*)$ /$api_path break; proxy_http_version 1.1; @@ -105,6 +111,8 @@ location /assets { # 站点图标 location /api/v1/site/icon/ { + error_log /dev/null crit; + # 站点图标缓存 proxy_cache my_cache; # 缓存响应码为200和302的请求1小时