diff --git a/data/conf/nginx/site.conf b/data/conf/nginx/site.conf index 0658c466..fddae9f4 100644 --- a/data/conf/nginx/site.conf +++ b/data/conf/nginx/site.conf @@ -116,6 +116,16 @@ server { } location /rspamd/ { + location /rspamd/auth { + # proxy_pass is not inherited + proxy_pass http://rspamd:11334/auth; + proxy_intercept_errors on; + proxy_set_header Host $http_host; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Real-IP $remote_addr; + proxy_redirect off; + error_page 403 /_rspamderror.php; + } proxy_pass http://rspamd:11334/; proxy_set_header Host $http_host; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; @@ -207,6 +217,7 @@ server { include /etc/nginx/conf.d/site.*.custom; error_page 502 @awaitingupstream; + location @awaitingupstream { rewrite ^(.*)$ /_status.502.html break; }