kolla-ansible/ansible/roles/rabbitmq/templates/rabbitmq.config.j2
Jeffrey Zhang e7441a4212 Configure the rabbitmq ha policy in config file
Closes-Bug: #1580884
Change-Id: Ief5917d48dbf6abe4a5861e73b24d534b889bd52
2016-05-23 10:27:33 +08:00

23 lines
846 B
Django/Jinja

[
{kernel, [
{inet_dist_use_interface, {% raw %}{{% endraw %}{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] | regex_replace('\.', ',') }}}},
{inet_dist_listen_min, {{ rabbitmq_cluster_port }}},
{inet_dist_listen_max, {{ rabbitmq_cluster_port }}}
]},
{rabbit, [
{tcp_listeners, [
{"{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}", {{ rabbitmq_port }}}
]},
{cluster_partition_handling, autoheal}
]},
{rabbitmq_management, [
{listener, [
{ip, "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"},
{port, {{ rabbitmq_management_port }}}
]},
{load_definitions, "/etc/rabbitmq/definitions.json"}
]},
{rabbitmq_clusterer, [{config, "/etc/rabbitmq/rabbitmq-clusterer.config"}]}
].
% EOF