wujie1993 / nginx-websocket-proxy

nginx WebSocket Proxy

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

nginx WebSocket Proxy

As of version 1.4, nginx is capable of forwarding WebSocket requests, so it can be used as a reverse proxy for HTTP, HTTPS, WS and WSS.

Here are some simple example configuration snippets for WebSocket forwarding in nginx.

Requirements

  • nginx 1.4.x or higher
  • WebSocket and HTTP server running on ws|http://localhost:8080

This is a typical scenario given by Engine.IO, Socket.IO, Primus, etc. which provide a WebSocket server with HTTP fallback.

Example Configs

See Also

Author

Nico Kaiser

License

MIT License

About

nginx WebSocket Proxy

License:MIT License