Using Nginx and HAProxy as Reverse Proxies for WebSocket Proxying

This guide walks you through setting up Nginx and HAProxy as reverse proxies for WebSocket proxying, including handling both ws and wss connections. The example will use the GoLang WebSocket implementation. Prerequisites: To follow this guide, you’ll need: A Linux server with sudo privileges Nginx and HAProxy installed on the server Go installed on the server Part I: Setting up the Go WebSocket Server Let’s start by creating a simple WebSocket server in Go....

June 2, 2023 · 4 min · 769 words · Alexander M.