server { listen 8088; server_name localhost 127.0.0.1; # location ^~ / { root /var/www/ws_rtsp_proxy/; index index.html; # } location / { try_files $uri $uri/ =404; } location = /ws/ { proxy_pass http://127.0.0.1:8080/ws/; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_read_timeout 90s; } }