Skip to content

Instantly share code, notes, and snippets.

@exceptionplayer
Forked from yllan/nginx.conf
Created April 12, 2019 10:53
Show Gist options
  • Save exceptionplayer/f649cda52e5b068dedcac486cda06e9e to your computer and use it in GitHub Desktop.
Save exceptionplayer/f649cda52e5b068dedcac486cda06e9e to your computer and use it in GitHub Desktop.
設定 nginx 使用 server sent event
location xxxx {
proxy_pass http://localhost:9000;
proxy_buffering off;
proxy_cache off;
proxy_redirect off;
proxy_set_header Connection '';
proxy_http_version 1.1;
chunked_transfer_encoding off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment