~hopem/charms/trusty/cinder/ensure-apache-restart

« back to all changes in this revision

Viewing changes to hooks/charmhelpers/contrib/openstack/templates/haproxy.cfg

  • Committer: Liam Young
  • Date: 2015-01-09 16:02:39 UTC
  • mfrom: (65 cinder.next)
  • mto: This revision was merged to the branch mainline in revision 67.
  • Revision ID: liam.young@canonical.com-20150109160239-qldk423wxfno2ao3
Merged next in and resolved conflicts

Show diffs side-by-side

added added

removed removed

Lines of Context:
35
35
    stats auth admin:password
36
36
 
37
37
{% if frontends -%}
38
 
{% for service, ports in service_ports.iteritems() -%}
 
38
{% for service, ports in service_ports.items() -%}
39
39
frontend tcp-in_{{ service }}
40
40
    bind *:{{ ports[0] }}
 
41
    {% if ipv6 -%}
41
42
    bind :::{{ ports[0] }}
 
43
    {% endif -%}
42
44
    {% for frontend in frontends -%}
43
45
    acl net_{{ frontend }} dst {{ frontends[frontend]['network'] }}
44
46
    use_backend {{ service }}_{{ frontend }} if net_{{ frontend }}
46
48
{% for frontend in frontends -%}
47
49
backend {{ service }}_{{ frontend }}
48
50
    balance leastconn
49
 
    {% for unit, address in frontends[frontend]['backends'].iteritems() -%}
 
51
    {% for unit, address in frontends[frontend]['backends'].items() -%}
50
52
    server {{ unit }} {{ address }}:{{ ports[1] }} check
51
53
    {% endfor %}
52
54
{% endfor -%}