comparison host/startup/nginx/nginx.default.conf.luan @ 1742:d778f1f2598a

make server side events proxy work
author Vadim Filimonov <fffilimonov@yandex.ru>
date Tue, 08 Nov 2022 09:32:46 +0200
parents 0344a535b1db
children
comparison
equal deleted inserted replaced
1741:623d9f62ab92 1742:d778f1f2598a
3 %> 3 %>
4 client_max_body_size 32m; 4 client_max_body_size 32m;
5 5
6 proxy_http_version 1.1; 6 proxy_http_version 1.1;
7 proxy_set_header Host $http_host; 7 proxy_set_header Host $http_host;
8 proxy_set_header Connection '';
9
8 error_log <%=rootDir%>/logs/nginx_error.log; 10 error_log <%=rootDir%>/logs/nginx_error.log;
9 11
10 proxy_set_header X-Forwarded-Proto $scheme; 12 proxy_set_header X-Forwarded-Proto $scheme;
11 proxy_set_header X-Real-IP $remote_addr; 13 proxy_set_header X-Real-IP $remote_addr;
12 14
16 default_type text/plain; 18 default_type text/plain;
17 return 200 "$1.<%=leKey%>"; 19 return 200 "$1.<%=leKey%>";
18 } 20 }
19 21
20 location ~ /(?<path>.*) { 22 location ~ /(?<path>.*) {
23 chunked_transfer_encoding off;
21 proxy_cache_key $scheme$host$request_uri; 24 proxy_cache_key $scheme$host$request_uri;
22 proxy_cache nginx_cache; 25 proxy_cache nginx_cache;
23 proxy_cache_revalidate on; 26 proxy_cache_revalidate on;
24 proxy_cache_min_uses 1; 27 proxy_cache_min_uses 1;
25 proxy_cache_use_stale error timeout updating http_500 http_502 http_503 http_504; 28 proxy_cache_use_stale error timeout updating http_500 http_502 http_503 http_504;