# Add this inside the server { } block for ai-sandbox.oliver.solutions # nginx -t && nginx -s reload location /hm-ai-qc-report { # Strip prefix and proxy to container rewrite ^/hm-ai-qc-report(/.*)$ $1 break; rewrite ^/hm-ai-qc-report$ / break; proxy_pass http://127.0.0.1:5050; # Tell Flask what the original prefix was proxy_set_header X-Script-Name /hm-ai-qc-report; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header Host $host; # Large file uploads (PDFs, videos) client_max_body_size 500M; # Long-running requests (QC execution, Box searches) proxy_read_timeout 180s; proxy_connect_timeout 10s; proxy_send_timeout 60s; # SSE support (disable buffering for progress streams) proxy_buffering off; proxy_cache off; }