nginx-proxy-manager icon indicating copy to clipboard operation
nginx-proxy-manager copied to clipboard

feat(streams): Simple Load Balancing of Streams

Open Teagan42 opened this issue 1 year ago • 6 comments

Credit to https://github.com/eedev - Their PR was marked stale: https://github.com/NginxProxyManager/nginx-proxy-manager/pull/1999

Motivation

I wanted to use Nginx Proxy Manager to do some simple load balancing for a EMQX cluster, seems I am not alone:

  • #156
  • #1963
  • #2840

Description

I followed #1999 - unfortunately, that PR is very stale, so it was easier to branch off of upstream develop and re-implement the changes and perform the eslint fixes.

If your stream contains multiple upstreams - it will use the least connection strategy and max_fails=3

Alternative Approaches

A more robust solution would allow for specifying the upstream port for each of the forwarding hosts (upstreams). I did toy around with this but decided it was more work than I wanted to do right now and was worried it may break other user configurations.

Future Enhancements

  • Advanced Options: Load Balancing Strategies, Allow Different Ports per Upstream, Other Proxy Settings
  • SSL

Screenshots

image

Teagan42 avatar Jun 30 '24 00:06 Teagan42

Docker Image for build 2 is available on DockerHub as jc21/nginx-proxy-manager:github-pr-3841

Note: ensure you backup your NPM instance before testing this PR image! Especially if this PR contains database changes.

希望能把此pr能合并,正需要此功能

z499738316 avatar Aug 01 '24 13:08 z499738316

Please merge it

CRASH-Tech avatar Oct 12 '24 10:10 CRASH-Tech

this would be great, thanks

JohnnyBoomKek avatar Oct 16 '24 18:10 JohnnyBoomKek

+1

Fahl-Design avatar Mar 21 '25 19:03 Fahl-Design

+1

saruman67 avatar Jul 28 '25 09:07 saruman67