Use active_passive parameter for existing services

MariaDB is left unchanged because its custom_member_list uses a
different group (mariadb_default_database_shard_hosts).

Change-Id: Icefd5a3d02ae4dfeb27401696c35ca2c38e203d3
This commit is contained in:
Pierre Riteau 2022-08-29 14:38:02 +02:00
parent 438ff2307c
commit f7b1221032
2 changed files with 2 additions and 8 deletions

View File

@ -19,12 +19,7 @@ memcached_services:
backend_tcp_extra: backend_tcp_extra:
- "option srvtcpka" - "option srvtcpka"
- "timeout server 3600s" - "timeout server 3600s"
custom_member_list: "{{ haproxy_members.split(';') }}" active_passive: true
####################
# HAProxy
####################
haproxy_members: "{% for host in groups['memcached'] %}server {{ hostvars[host].ansible_facts.hostname }} {{ 'api' | kolla_address(host) }}:{{ memcached_port }} check inter 2000 rise 2 fall 5{% if not loop.first %} backup{% endif %};{% endfor %}"
#################### ####################
# Docker # Docker

View File

@ -13,7 +13,7 @@ prometheus_services:
mode: "http" mode: "http"
external: false external: false
port: "{{ prometheus_port }}" port: "{{ prometheus_port }}"
custom_member_list: "{{ prometheus_haproxy_members.split(';') }}" active_passive: "{{ prometheus_active_passive | bool }}"
prometheus-node-exporter: prometheus-node-exporter:
container_name: prometheus_node_exporter container_name: prometheus_node_exporter
group: prometheus-node-exporter group: prometheus-node-exporter
@ -132,7 +132,6 @@ prometheus_mysql_exporter_database_user: "{% if use_preconfigured_databases | bo
# HAProxy # HAProxy
#################### ####################
prometheus_active_passive: true prometheus_active_passive: true
prometheus_haproxy_members: "{% for host in groups['prometheus'] %}server {{ hostvars[host].ansible_facts.hostname }} {{ 'api' | kolla_address(host) }}:{{ prometheus_port }} check inter 2000 rise 2 fall 5{% if not loop.first %}{% if prometheus_active_passive | bool %} backup{% endif %}{% endif %};{% endfor %}"
#################### ####################
# Blackbox # Blackbox