Don't enforce the use of lb_method in upstream. (#199)

This commit is contained in:
Pritpal Sabharwal 2019-11-28 19:21:32 -08:00 committed by Alessandro Fael Garcia
parent e4e68376f5
commit f56855bd16

View File

@ -3,7 +3,9 @@
{% if item.value.upstreams is defined and item.value.upstreams %}
{% for upstream in item.value.upstreams %}
upstream {{ item.value.upstreams[upstream].name }} {
{% if item.value.upstreams[upstream].lb_method is defined and item.value.upstreams[upstream].lb_method | length %}
{{ item.value.upstreams[upstream].lb_method }};
{% endif %}
{% if item.value.upstreams[upstream].zone_name is defined and item.value.upstreams[upstream].zone_name %}
zone {{ item.value.upstreams[upstream].zone_name }} {{ item.value.upstreams[upstream].zone_size }};
{% endif %}