# Place the map and server inside nginx's http {} context. Replace the TLS # files and upstream for your installation. Keep DSH's listener private. map $http_upgrade $connection_upgrade { default upgrade; '' close; } server { listen 443 ssl; server_name dsh.example.com; ssl_certificate /etc/nginx/tls/dsh.example.com.crt; ssl_certificate_key /etc/nginx/tls/dsh.example.com.key; location / { proxy_pass http://127.0.0.1:13090; proxy_http_version 1.1; proxy_set_header Host $http_host; proxy_set_header Origin $http_origin; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection $connection_upgrade; proxy_buffering off; proxy_request_buffering off; proxy_cache off; proxy_read_timeout 3600s; proxy_send_timeout 3600s; } }