Set ceph_mons in group_vars
ceph_mons is used by the OSA ceph_client role, since it does not support consuming the list of mons from a group name which is what upstream ceph-ansible uses. So we will generate the list of mons using the group name and prepare it for ceph_client. This defaults the configuration to use the integrated ceph-ansible managed ceph cluster deployment in OSA. However, if the OSA deployer is using an externally managed cluster, they should still be able to override ceph_mons in user_variables. Change-Id: Ida44228c2d2919990bac46936317b6093d3ff115
This commit is contained in:
@@ -29,3 +29,9 @@ fetch_directory: /etc/openstack_deploy/ceph-fetch/
|
||||
# exists. we handle the log dir creation so this is not something we need
|
||||
# ceph-common to prepare for us.
|
||||
rbd_client_directories: false
|
||||
|
||||
# The OSA ceph_client role does not support loading IPs from an inventory group,
|
||||
# so we have to feed it a list of IPs
|
||||
ceph_mons: "{{ groups[mon_group_name]
|
||||
| map('extract', hostvars, 'ansible_host')
|
||||
| list }}"
|
||||
|
||||
@@ -54,9 +54,6 @@
|
||||
content: |
|
||||
---
|
||||
devices: {{ ceph_create_loopback.results | map(attribute='stdout') | list | to_yaml | trim }}
|
||||
# The OSA ceph_client role does not support loading IPs from an inventory group,
|
||||
# so we have to feed it a list of IPs
|
||||
ceph_mons: "{% raw %}[ {% for host in groups[mon_group_name] %}'{{ hostvars[host]['ansible_host'] }}'{% if not loop.last %},{% endif %}{% endfor %} ]{% endraw %}"
|
||||
cinder_backends:
|
||||
"RBD":
|
||||
volume_driver: cinder.volume.drivers.rbd.RBDDriver
|
||||
|
||||
Reference in New Issue
Block a user