Skip to content

global/defaults config bloc support #119

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -48,6 +48,12 @@ Example
- hosts: loadbalancers
roles:
- role: haproxy
haproxy_global:
- address: "/dev/log"
facility: "local0"
level: "info"
haproxy_extra_global_options: |
hard-stop-after 30s
haproxy_frontends:
- name: 'fe-mysupersite'
ip: '123.123.123.120'
3 changes: 3 additions & 0 deletions defaults/main.yml
Original file line number Diff line number Diff line change
@@ -72,3 +72,6 @@ haproxy_backends: []
haproxy_frontends: []
haproxy_listen: []
haproxy_userlists: []

haproxy_extra_global_options: []
haproxy_extra_defaults_options: []
4 changes: 3 additions & 1 deletion templates/defaults.cfg
Original file line number Diff line number Diff line change
@@ -85,4 +85,6 @@ defaults
http-check send-state
{% endif -%}
{% endif -%}

{% if haproxy_extra_defaults_options %}
{{ haproxy_extra_defaults_options }}
{% endif %}
3 changes: 3 additions & 0 deletions templates/global.cfg
Original file line number Diff line number Diff line change
@@ -62,3 +62,6 @@ global
tune.{{ param }} {{ value }}
{% endfor -%}
{% endif %}
{% if haproxy_extra_global_options %}
{{ haproxy_extra_global_options }}
{% endif %}