diff options
| author | Éric Lemoine <elemoine@mirantis.com> | 2016-02-03 11:55:14 +0100 |
|---|---|---|
| committer | Sam Yaple <sam@yaple.net> | 2016-02-19 20:32:10 +0000 |
| commit | 3fca4ccbaf66eedc6035826afd842cde02049ba7 (patch) | |
| tree | d1976c7798d490e7acd688cba20231a479d6001e /ansible/roles/haproxy | |
| parent | 916925c9a80f90fbe2c18cbfd9b6499257431e2b (diff) | |
| download | kolla-3fca4ccbaf66eedc6035826afd842cde02049ba7.tar.gz kolla-3fca4ccbaf66eedc6035826afd842cde02049ba7.zip | |
Make Heka collect HAProxy and Keepalived logs
Partially implements: blueprint heka
Change-Id: I7e2bf4e520fa14fd40e3b329f3b2998ae6ea47f4
Diffstat (limited to 'ansible/roles/haproxy')
| -rw-r--r-- | ansible/roles/haproxy/tasks/start.yml | 2 | ||||
| -rw-r--r-- | ansible/roles/haproxy/templates/haproxy.cfg.j2 | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/ansible/roles/haproxy/tasks/start.yml b/ansible/roles/haproxy/tasks/start.yml index 0193350f7..352311d94 100644 --- a/ansible/roles/haproxy/tasks/start.yml +++ b/ansible/roles/haproxy/tasks/start.yml @@ -9,6 +9,7 @@ volumes: - "{{ node_config_directory }}/haproxy/:{{ container_config_directory }}/:ro" - "haproxy_socket:/var/lib/kolla/haproxy/" + - "heka_socket:/var/lib/kolla/heka/" - name: Starting keepalived container kolla_docker: @@ -21,6 +22,7 @@ - "{{ node_config_directory }}/keepalived/:{{ container_config_directory }}/:ro" - "/lib/modules:/lib/modules:ro" - "haproxy_socket:/var/lib/kolla/haproxy/" + - "heka_socket:/var/lib/kolla/heka/" - name: Ensuring latest haproxy config is used command: docker exec haproxy /usr/local/bin/kolla_ensure_haproxy_latest_config diff --git a/ansible/roles/haproxy/templates/haproxy.cfg.j2 b/ansible/roles/haproxy/templates/haproxy.cfg.j2 index d45682d31..f56daa854 100644 --- a/ansible/roles/haproxy/templates/haproxy.cfg.j2 +++ b/ansible/roles/haproxy/templates/haproxy.cfg.j2 @@ -1,11 +1,14 @@ global daemon + log /var/lib/kolla/heka/log local0 maxconn 4000 stats socket /var/lib/kolla/haproxy/haproxy.sock defaults + log global mode http option redispatch + option httplog retries 3 timeout http-request 10s timeout queue 1m @@ -25,6 +28,7 @@ listen stats {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4'] {% if enable_mariadb | bool %} listen mariadb mode tcp + option tcplog option tcpka option mysql-check user haproxy bind {{ kolla_internal_address }}:{{ mariadb_port }} |
