]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
mon: do not hardcode ipv4 1548/head
authorSébastien Han <seb@redhat.com>
Thu, 18 May 2017 09:56:55 +0000 (11:56 +0200)
committerSébastien Han <seb@redhat.com>
Thu, 18 May 2017 09:56:55 +0000 (11:56 +0200)
Problem: fail to deploy a containerized Ceph cluster with ipv6
Solution: do not hardcode ipv4 when bootstrapping the container.

Now use ip_version: ipv6 to get a containerized cluster deployed with
ipv6.

Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1451786
Signed-off-by: Sébastien Han <seb@redhat.com>
roles/ceph-mon/templates/ceph-mon.service.j2

index f231d2bfb213b0679089bc71f343de81a9332fa3..014046f3e2311f7970a81fab9c2bb4ea5fc27d8e 100644 (file)
@@ -23,7 +23,7 @@ ExecStart=/usr/bin/docker run --rm --name ceph-mon-%i --net=host \
    --net=host \
    {% endif -%}
    -e CEPH_DAEMON=MON \
-   -e MON_IP={{ hostvars[inventory_hostname]['ansible_' + ceph_mon_docker_interface]['ipv4']['address'] }} \
+   -e MON_IP={{ hostvars[inventory_hostname]['ansible_' + ceph_mon_docker_interface][ip_version]['address'] }} \
    -e CEPH_PUBLIC_NETWORK={{ ceph_mon_docker_subnet }} \
    {{ ceph_mon_docker_extra_env }} \
    {{ceph_docker_registry }}/{{ ceph_docker_image }}:{{ ceph_docker_image_tag }}