server { listen 8080; server_name _; root /usr/share/nginx/html; index index.html; client_max_body_size 1m; gzip on; gzip_types text/css application/javascript application/json image/svg+xml; gzip_min_length 1024; add_header X-Content-Type-Options nosniff always; add_header Referrer-Policy same-origin always; add_header Content-Security-Policy "default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:; connect-src 'self'; font-src 'self'; frame-ancestors 'none'; object-src 'none'; base-uri 'self'; form-action 'self'" always; location /api/ { proxy_pass http://api:8081; proxy_http_version 1.1; proxy_set_header Host $http_host; proxy_set_header Connection ''; proxy_buffering off; proxy_read_timeout 3600s; } location = /mcp { proxy_pass http://api:8081; proxy_http_version 1.1; proxy_set_header Host $http_host; proxy_set_header Connection ''; proxy_buffering off; proxy_read_timeout 120s; } location /hooks/ { proxy_pass http://api:8081; proxy_http_version 1.1; proxy_set_header Host $http_host; proxy_set_header Connection ''; proxy_read_timeout 30s; } location /assets/ { expires 30d; try_files $uri =404; } location / { expires -1; try_files $uri $uri/ /index.html; } }