mirror of
https://github.com/netbirdio/plugins.git
synced 2026-05-22 18:44:07 -07:00
+1
-1
@@ -1,5 +1,5 @@
|
||||
PLUGIN_NAME= nginx
|
||||
PLUGIN_VERSION= 1.13
|
||||
PLUGIN_VERSION= 1.14
|
||||
PLUGIN_COMMENT= Nginx HTTP server and reverse proxy
|
||||
PLUGIN_DEPENDS= nginx
|
||||
PLUGIN_MAINTAINER= franz.fabian.94@gmail.com
|
||||
|
||||
@@ -8,6 +8,10 @@ reuse, SSL offload and HTTP media streaming.
|
||||
Plugin Changelog
|
||||
================
|
||||
|
||||
1.14
|
||||
|
||||
* add load balancer algorithm option (ip_hash)
|
||||
|
||||
1.13
|
||||
|
||||
* add support for 0-RTT (Early Data in TLS 1.3)
|
||||
|
||||
@@ -10,6 +10,12 @@
|
||||
<style>selectpicker</style>
|
||||
<type>select_multiple</type>
|
||||
</field>
|
||||
<field>
|
||||
<id>upstream.load_balancing_algorithm</id>
|
||||
<label>Load Balancing Algorithm</label>
|
||||
<style>selectpicker</style>
|
||||
<type>dropdown</type>
|
||||
</field>
|
||||
<field>
|
||||
<id>upstream.proxy_protocol</id>
|
||||
<label>PROXY Protocol</label>
|
||||
|
||||
@@ -82,6 +82,13 @@
|
||||
<Required>Y</Required>
|
||||
<multiple>Y</multiple>
|
||||
</serverentries>
|
||||
<load_balancing_algorithm type="OptionField">
|
||||
<OptionValues>
|
||||
<ip_hash>IP Hash</ip_hash>
|
||||
</OptionValues>
|
||||
<BlankDesc>Weighted Round Robin</BlankDesc>
|
||||
<Required>N</Required>
|
||||
</load_balancing_algorithm>
|
||||
<proxy_protocol type="BooleanField">
|
||||
<default>0</default>
|
||||
<Required>Y</Required>
|
||||
|
||||
@@ -7,6 +7,11 @@
|
||||
{% endfor %}
|
||||
{% for upstream_uuid, upstream in upstreamlist.items() %}
|
||||
upstream upstream{{ upstream_uuid.replace('-','') }} {
|
||||
{% if upstream.load_balancing_algorithm is defined and upstream.load_balancing_algorithm != '' %}
|
||||
{% if upstream.load_balancing_algorithm == 'ip_hash' %}
|
||||
ip_hash;
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% for upstream_serveruuid in upstream.serverentries.split(',') %}
|
||||
{% set upstream_server = helpers.getUUID(upstream_serveruuid) %}
|
||||
server {% if ':' in upstream_server.server %}[{% endif %}{{ upstream_server.server }}{% if ':' in upstream_server.server %}]{% endif
|
||||
|
||||
Reference in New Issue
Block a user