mirror of https://github.com/ceph/ceph-ansible.git
ceph-mon: move the ceph_config call to ceph-mon role
ba7eb62a1b
broke deployments where
mgrs are not collocated with mons.
Signed-off-by: Guillaume Abrioux <gabrioux@ibm.com>
pull/7551/head
parent
ba7eb62a1b
commit
4f6641fe5c
|
@ -94,22 +94,6 @@
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
num_osds: "{{ num_osds | int + (lvm_list.stdout | default('{}') | from_json | dict2items | map(attribute='value') | flatten | map(attribute='devices') | sum(start=[]) | difference(lvm_volumes | default([]) | map(attribute='data')) | length | int) }}"
|
num_osds: "{{ num_osds | int + (lvm_list.stdout | default('{}') | from_json | dict2items | map(attribute='value') | flatten | map(attribute='devices') | sum(start=[]) | difference(lvm_volumes | default([]) | map(attribute='data')) | length | int) }}"
|
||||||
|
|
||||||
- name: Set cluster configs
|
|
||||||
ceph_config:
|
|
||||||
action: set
|
|
||||||
who: "{{ item.0.key }}"
|
|
||||||
option: "{{ item.1.key }}"
|
|
||||||
value: "{{ item.1.value }}"
|
|
||||||
run_once: true
|
|
||||||
delegate_to: "{{ running_mon }}"
|
|
||||||
when:
|
|
||||||
- item.1.value != omit
|
|
||||||
- running_mon is defined
|
|
||||||
loop: "{{ ceph_cluster_conf | dict2dict }}"
|
|
||||||
environment:
|
|
||||||
CEPH_CONTAINER_IMAGE: "{{ ceph_docker_registry + '/' + ceph_docker_image + ':' + ceph_docker_image_tag if containerized_deployment | bool else None }}"
|
|
||||||
CEPH_CONTAINER_BINARY: "{{ container_binary }}"
|
|
||||||
|
|
||||||
- name: Set osd related config facts
|
- name: Set osd related config facts
|
||||||
when: inventory_hostname in groups.get(osd_group_name, [])
|
when: inventory_hostname in groups.get(osd_group_name, [])
|
||||||
block:
|
block:
|
||||||
|
|
|
@ -23,3 +23,17 @@
|
||||||
when:
|
when:
|
||||||
- secure_cluster | bool
|
- secure_cluster | bool
|
||||||
- inventory_hostname == groups[mon_group_name] | first
|
- inventory_hostname == groups[mon_group_name] | first
|
||||||
|
|
||||||
|
- name: Set cluster configs
|
||||||
|
ceph_config:
|
||||||
|
action: set
|
||||||
|
who: "{{ item.0.key }}"
|
||||||
|
option: "{{ item.1.key }}"
|
||||||
|
value: "{{ item.1.value }}"
|
||||||
|
run_once: true
|
||||||
|
when:
|
||||||
|
- item.1.value != omit
|
||||||
|
loop: "{{ ceph_cluster_conf | dict2dict }}"
|
||||||
|
environment:
|
||||||
|
CEPH_CONTAINER_IMAGE: "{{ ceph_docker_registry + '/' + ceph_docker_image + ':' + ceph_docker_image_tag if containerized_deployment | bool else None }}"
|
||||||
|
CEPH_CONTAINER_BINARY: "{{ container_binary }}"
|
||||||
|
|
Loading…
Reference in New Issue