server { server_name 10.10.7.251; root /home/ubuntu/pra-react/build; index index.html index.htm index.nginx-debian.html; location ~ ^/(staticpra|api/) { proxy_pass http://localhost:443; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header X-Real-IP $remote_addr; proxy_set_header Connection 'upgrade'; proxy_set_header Host $host; proxy_cache_bypass $http_upgrade; } client_max_body_size 24000M; location / { try_files $uri /index.html; # kill cache add_header Last-Modified $date_gmt; add_header Cache-Control 'no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0'; if_modified_since off; expires off; etag off; } listen 443 ssl; # managed by Certbot } }