mirror of
https://github.com/Alvin-Zilverstand/nginx-proxy-manager.git
synced 2026-11-28 08:57:53 +01:00
Add reuseport to improve performance and reduce packet drops
This commit is contained in:
1 parent
cdde543e8a
commit
e72dfc3bfd
1 file changed
+4
-4
@@ -5,8 +5,8 @@
|
|||||||
{% if enabled %}
|
{% if enabled %}
|
||||||
{% if tcp_forwarding == 1 or tcp_forwarding == true -%}
|
{% if tcp_forwarding == 1 or tcp_forwarding == true -%}
|
||||||
server {
|
server {
|
||||||
listen {{ incoming_port }} {%- if certificate %} ssl {%- endif %};
|
listen {{ incoming_port }} reuseport {%- if certificate %} ssl {%- endif %};
|
||||||
{% unless ipv6 -%} # {%- endunless -%} listen [::]:{{ incoming_port }} {%- if certificate %} ssl {%- endif %};
|
{% unless ipv6 -%} # {%- endunless -%} listen [::]:{{ incoming_port }} reuseport {%- if certificate %} ssl {%- endif %};
|
||||||
|
|
||||||
{%- include "_certificates_stream.conf" %}
|
{%- include "_certificates_stream.conf" %}
|
||||||
|
|
||||||
@@ -23,8 +23,8 @@ server {
|
|||||||
|
|
||||||
{% if udp_forwarding == 1 or udp_forwarding == true -%}
|
{% if udp_forwarding == 1 or udp_forwarding == true -%}
|
||||||
server {
|
server {
|
||||||
listen {{ incoming_port }} udp;
|
listen {{ incoming_port }} udp reuseport;
|
||||||
{% unless ipv6 -%} # {%- endunless -%} listen [::]:{{ incoming_port }} udp;
|
{% unless ipv6 -%} # {%- endunless -%} listen [::]:{{ incoming_port }} udp reuseport;
|
||||||
|
|
||||||
proxy_pass {{ forwarding_host }}:{{ forwarding_port }};
|
proxy_pass {{ forwarding_host }}:{{ forwarding_port }};
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user