-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnginx.conf
More file actions
28 lines (24 loc) · 972 Bytes
/
Copy pathnginx.conf
File metadata and controls
28 lines (24 loc) · 972 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
server {
listen 8080 default_server;
client_max_body_size 100M;
location / {
root /usr/share/nginx/html;
try_files $uri $uri/ /index.html;
}
location /api/ {
proxy_pass http://backend:8000/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
# PDF extraction processes files sequentially with a rate-limit
# delay per file (see MODEL_SLEEP_SECONDS in backend/main.py), so a
# batch of several PDFs can take a few minutes. Worst case is a
# mid-batch fallback to gemini-flash-latest (~90s/file incl.
# sleep) rather than the primary gemini-3.5-flash-lite (~9s/file) —
# sized for batches up to ~15 PDFs in that worst case (15 * 90s =
# 1350s), with margin. Raise this further if you routinely batch
# more files.
proxy_connect_timeout 300s;
proxy_send_timeout 1500s;
proxy_read_timeout 1500s;
}
}