kolla-ansible/ansible/roles/haproxy/templates/haproxy.json.j2
Jeffrey Zhang be6798fc30 Compatible with ubuntu 18.04
Depends-On: https://review.openstack.org/568529
Change-Id: I8084e4c8406c818589ca984afe5b5364c00b08ca
2018-05-16 18:00:44 +08:00

20 lines
718 B
Django/Jinja

{% set haproxy_cmd='/usr/sbin/haproxy -W -db' if kolla_base_distro in ['ubuntu'] else '/usr/sbin/haproxy-systemd-wrapper' %}
{
"command": "{{ haproxy_cmd }} -f /etc/haproxy/haproxy.cfg -p /run/haproxy.pid",
"config_files": [
{
"source": "{{ container_config_directory }}/haproxy.cfg",
"dest": "/etc/haproxy/haproxy.cfg",
"owner": "root",
"perm": "0600"
},
{
"source": "{{ container_config_directory }}/haproxy.pem",
"dest": "/etc/haproxy/haproxy.pem",
"owner": "root",
"perm": "0600",
"optional": {{ (not kolla_enable_tls_external | bool) | string | lower }}
}
]
}