From 06ce643f7d29733f0a97dac21c392c45bef98a6f Mon Sep 17 00:00:00 2001 From: Andrew Schoen Date: Tue, 8 Nov 2016 09:58:35 -0600 Subject: [PATCH] common: reformat mon_initial_members with indention Signed-off-by: Andrew Schoen Resolves: testing#updates --- roles/ceph-common/templates/ceph.conf.j2 | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/roles/ceph-common/templates/ceph.conf.j2 b/roles/ceph-common/templates/ceph.conf.j2 index 7cf82fe5f..5b50e1d3e 100644 --- a/roles/ceph-common/templates/ceph.conf.j2 +++ b/roles/ceph-common/templates/ceph.conf.j2 @@ -17,7 +17,14 @@ osd crush chooseleaf type = 0 {% endif %} {# NOTE (leseb): the blank lines in-between are needed otherwise we won't get any line break #} {% if groups[mon_group_name] is defined %} -mon initial members = {% if groups[mon_group_name] is defined %}{% for host in groups[mon_group_name] %}{% if hostvars[host]['ansible_fqdn'] is defined and mon_use_fqdn %}{{ hostvars[host]['ansible_fqdn'] }}{% if not loop.last %},{% endif %}{% elif hostvars[host]['ansible_hostname'] is defined %}{{ hostvars[host]['ansible_hostname'] }}{% if not loop.last %},{% endif %}{% endif %}{% endfor %}{% endif %} +mon initial members = {% for host in groups[mon_group_name] %} + {% if hostvars[host]['ansible_fqdn'] is defined and mon_use_fqdn -%} + {{ hostvars[host]['ansible_fqdn'] }} + {%- elif hostvars[host]['ansible_hostname'] is defined -%} + {{ hostvars[host]['ansible_hostname'] }} + {%- endif %} + {%- if not loop.last %},{% endif %} + {% endfor %} {% endif %} {% if not mon_containerized_deployment and not mon_containerized_deployment_with_kv %} -- 2.47.3