Skip to content

Commit

Permalink
Make unique-id-format configurable
Browse files Browse the repository at this point in the history
  • Loading branch information
tgeywitz-transporeon committed Jul 27, 2023
1 parent 2a17a45 commit 91a12a9
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ haproxy_default_errorfiles:
- "403 {{ haproxy_errors_directory }}/403.http"
haproxy_default_http_check:
haproxy_default_monitor_uri:
haproxy_default_unique_id_format:

# Userlist
haproxy_userlist:
Expand Down
1 change: 1 addition & 0 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ haproxy_default_errorfiles:
- "403 {{ haproxy_errors_directory }}/403.http"
# haproxy_default_http_check:
# haproxy_default_monitor_uri:
# haproxy_default_unique_id_format:

# Stats
haproxy_stats: true
Expand Down
3 changes: 3 additions & 0 deletions templates/etc/haproxy/haproxy-default.cfg.j2
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,6 @@ defaults
{% if haproxy_default_mode is defined and haproxy_default_mode | length > 0 %}
mode {{ haproxy_default_mode }}
{% endif %}
{% if haproxy_default_unique_id_format is defined and haproxy_default_unique_id_format | length %}
unique-id-format {{ haproxy_default_unique_id_format }}
{% endif %}
3 changes: 3 additions & 0 deletions templates/etc/haproxy/haproxy-frontend.cfg.j2
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,9 @@ frontend {{ name }}
{% if value.default_backend is defined %}
default_backend {{ value.default_backend }}
{% endif %}
{% if value.unique_id_format is defined %}
unique-id-format {{ value.unique_id_format }}
{% endif %}
{% endfor %}

{% endfor %}
Expand Down
3 changes: 3 additions & 0 deletions templates/etc/haproxy/haproxy-listen.cfg.j2
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,9 @@ listen {{ name }}
log-format {{ log_format }}
{% endfor %}
{% endif %}
{% if value.unique_id_format is defined %}
unique-id-format {{ value.unique_id_format }}
{% endif %}
{% endfor %}

{% endfor %}
Expand Down

0 comments on commit 91a12a9

Please sign in to comment.