File tree 1 file changed +20
-3
lines changed
1 file changed +20
-3
lines changed Original file line number Diff line number Diff line change 1
1
pid /tmp/nginx.pid;
2
2
3
+ worker_processes auto;
4
+
3
5
events {
4
6
worker_connections 1024 ;
7
+ multi_accept on ;
5
8
}
6
9
7
10
http {
10
13
'' close;
11
14
}
12
15
13
- upstream server {
16
+ upstream streamlit {
14
17
server 127.0.0.1:8501;
15
18
}
16
19
@@ -24,11 +27,25 @@ http {
24
27
proxy_http_version 1.1 ;
25
28
proxy_set_header Upgrade $http_upgrade ;
26
29
proxy_set_header Connection $connection_upgrade ;
27
- proxy_pass http://server ;
30
+ proxy_pass http://streamlit ;
28
31
auth_basic off ;
29
32
}
30
33
31
- location /health {
34
+ # Streamlit endpoints
35
+ location /static {
36
+ proxy_pass http://streamlit;
37
+ }
38
+
39
+ location /stream {
40
+ proxy_http_version 1.1 ;
41
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
42
+ proxy_set_header Upgrade $http_upgrade ;
43
+ proxy_set_header Connection $connection_upgrade ;
44
+ proxy_set_header Host $http_host ;
45
+ proxy_pass http://streamlit;
46
+ }
47
+
48
+ location /healthz {
32
49
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
33
50
proxy_set_header Host $http_host ;
34
51
add_header Content-Type text/plain;
You can’t perform that action at this time.
0 commit comments