Skip to content

Commit

Permalink
Haproxy: Add the ability to define a backend port in the server list
Browse files Browse the repository at this point in the history
  • Loading branch information
quartje committed Jul 18, 2024
1 parent 6622e3d commit 19dd3c2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion roles/haproxy/templates/haproxy_backend.cfg.j2
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
cookie HTTPSERVERID insert nocache indirect httponly secure maxidle {{ haproxy_cookie_max_idle }}

{% for server in application.servers %}
server {{ server.label }} {{ server.ip }}:{{ application.port }} cookie {{ server.label }} check inter 8000 fall 5 rise 2 maxconn {{ application.maxconn | default('35') }} {% if application.sslbackend is defined%} ssl verify required verifyhost {{ application.backend_vhost_name }} ca-file {{ application.backend_ca_file }}{% endif %} weight 100
server {{ server.label }} {{ server.ip }}:{% if server.port is defined %}{{ server.port }}{% else %}{{ application.port }}{% endif %} cookie {{ server.label }} check inter 8000 fall 5 rise 2 maxconn {{ application.maxconn | default('35') }} {% if application.sslbackend is defined%} ssl verify required verifyhost {{ application.backend_vhost_name }} ca-file {{ application.backend_ca_file }}{% endif %} weight 100

{% endfor %}

Expand Down

0 comments on commit 19dd3c2

Please sign in to comment.