53 lines
1.6 KiB
Plaintext
53 lines
1.6 KiB
Plaintext
# meditron.tenvex.ru — PTSRaiAgent prototype (synthetic data only).
|
|
# / patient web app (static, web/dist)
|
|
# /api/ FastAPI (127.0.0.1:8010)
|
|
# /doctor/ Streamlit doctor dashboard + demo console (127.0.0.1:8511, baseUrlPath=doctor)
|
|
# TLS: after the DNS A-record exists — certbot --nginx -d meditron.tenvex.ru
|
|
|
|
map $http_upgrade $ptsr_connection_upgrade {
|
|
default upgrade;
|
|
'' close;
|
|
}
|
|
|
|
server {
|
|
listen 80;
|
|
listen [::]:80;
|
|
server_name meditron.tenvex.ru;
|
|
|
|
access_log /var/log/nginx/ptsr-access.log;
|
|
client_max_body_size 5m;
|
|
|
|
root /srv/ptsr/app/web/dist;
|
|
index index.html;
|
|
|
|
location / {
|
|
try_files $uri $uri/ /index.html;
|
|
}
|
|
|
|
location /api/ {
|
|
proxy_pass http://127.0.0.1:8010;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_set_header X-Forwarded-Proto $scheme;
|
|
proxy_read_timeout 120s; # chat agent + scheduler replay on clock advance
|
|
}
|
|
|
|
location ~ ^/(docs|openapi.json|health)$ {
|
|
proxy_pass http://127.0.0.1:8010;
|
|
proxy_set_header Host $host;
|
|
}
|
|
|
|
location /doctor/ {
|
|
proxy_pass http://127.0.0.1:8511;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection $ptsr_connection_upgrade;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_set_header X-Forwarded-Proto $scheme;
|
|
proxy_read_timeout 86400s;
|
|
proxy_buffering off;
|
|
}
|
|
}
|