7c632352a0
The behaviour of the `include` module is badly defined (it try to choose between statically importing the tasks and dynamically including them) and can cause problems depending on any number of constraints (mostly if it choose the wrong behaviour). Replace it with the `import_tasks` (always statically import tasks) unless the `include` is in a loop in which case we replace it with `include_tasks` (always dynamically include tasks). |
||
---|---|---|
.. | ||
defaults | ||
handlers | ||
meta | ||
tasks | ||
templates | ||
tests | ||
vars | ||
.kitchen.yml | ||
README.md |
haproxy
Install HAProxy.
Tasks
Everything is in the tasks/main.yml
file.
Available variables
haproxy_backports
: We can either prefer v1.7 from backports for Debian Jessie or v1.8 for Debian Stretch (default:False
)
Configuration templates
The roles compiles a haproxy.cfg
file based on templates that are looked up in that order :
{{ playbook_dir}}/templates/haproxy/haproxy.{{ inventory_hostname}}.cfg.j2
{{ playbook_dir}}/templates/haproxy/haproxy.{{ host_group}}.cfg.j2
(NB :host_group
is not a core variable, it must be defined ingroup_vars
files.){{ playbook_dir}}/templates/haproxy/haproxy.default.cfg.j2
If nothing is found, the role falls back to the template embedded in the role : templates/haproxy.default.cfg.j2