Merge pull request #1946 from ceph/fix_bug_collocation

config: fix path to set `interface` in ceph.conf
pull/1948/head
Sébastien Han 2017-09-23 19:28:00 +02:00 committed by GitHub
commit c6de5b13b3
3 changed files with 4 additions and 4 deletions

View File

@ -81,7 +81,7 @@ mon host = {% if nb_mon > 0 %}
[{{ hostvars[host]['monitor_address'] }}]
{%- endif %}
{%- else -%}
{% set interface = ["ansible_",monitor_interface]|join %}
{% set interface = 'ansible_' + hostvars[host]['monitor_interface'] %}
{% if ip_version == 'ipv4' -%}
{{ hostvars[host][interface][ip_version]['address'] }}
{%- elif ip_version == 'ipv6' -%}
@ -199,7 +199,7 @@ rgw data = /var/lib/ceph/radosgw/{{ cluster }}-rgw.{{ hostvars[host]['ansible_ho
rgw frontends = civetweb port=[{{ hostvars[host]['radosgw_address'] }}]:{{ radosgw_civetweb_port }} {{ radosgw_civetweb_options }}
{% endif %}
{%- else -%}
{% set interface = ["ansible_",radosgw_interface]|join %}
{% set interface = 'ansible_' + hostvars[host]['radosgw_interface'] %}
{% if ip_version == 'ipv6' -%}
rgw frontends = civetweb port=[{{ hostvars[host][interface][ip_version][0]['address'] }}]:{{ radosgw_civetweb_port }} {{ radosgw_civetweb_options }}
{%- elif ip_version == 'ipv4' -%}

View File

@ -42,7 +42,7 @@ ExecStart=/usr/bin/docker run --rm --name ceph-mon-%i --net=host \
-e MON_IP=[{{ hostvars[inventory_hostname]['monitor_address'] }}] \
{% endif -%}
{% else -%}
{% set interface = ["ansible_",monitor_interface]|join %}
{% set interface = 'ansible_' + hostvars[inventory_hostname]['monitor_interface'] %}
{% if ip_version == 'ipv6' -%}
-e MON_IP=[{{ hostvars[inventory_hostname][interface][ip_version][0]['address'] }}] \
{% elif ip_version == 'ipv4' -%}

View File

@ -34,7 +34,7 @@ ExecStart=/usr/bin/docker run --rm --net=host \
-e RGW_CIVETWEB_IP=[{{ hostvars[inventory_hostname]['radosgw_address'] }}] \
{% endif -%}
{% else -%}
{% set interface = ["ansible_",radosgw_interface]|join %}
{% set interface = 'ansible_' + hostvars[inventory_hostname]['radosgw_interface'] %}
{% if ip_version == 'ipv6' -%}
-e RGW_CIVETWEB_IP=[{{ hostvars[inventory_hostname][interface][ip_version][0]['address'] }}] \
{% elif ip_version == 'ipv4' -%}