diff --git a/group_vars/all.yml.sample b/group_vars/all.yml.sample index d785dbc18..06c715a1c 100644 --- a/group_vars/all.yml.sample +++ b/group_vars/all.yml.sample @@ -57,6 +57,18 @@ dummy: #mgr_group_name: mgrs #rgwloadbalancer_group_name: rgwloadbalancers #monitoring_group_name: monitoring +#adopt_label_group_names: +# - "{{ mon_group_name }}" +# - "{{ osd_group_name }}" +# - "{{ rgw_group_name }}" +# - "{{ mds_group_name }}" +# - "{{ nfs_group_name }}" +# - "{{ rbdmirror_group_name }}" +# - "{{ client_group_name }}" +# - "{{ iscsi_gw_group_name }}" +# - "{{ mgr_group_name }}" +# - "{{ rgwloadbalancer_group_name }}" +# - "{{ monitoring_group_name }}" # If configure_firewall is true, then ansible will try to configure the # appropriate firewalling rules so that Ceph daemons can communicate diff --git a/group_vars/rhcs.yml.sample b/group_vars/rhcs.yml.sample index 534dc271c..9de5774ad 100644 --- a/group_vars/rhcs.yml.sample +++ b/group_vars/rhcs.yml.sample @@ -57,6 +57,18 @@ dummy: #mgr_group_name: mgrs #rgwloadbalancer_group_name: rgwloadbalancers #monitoring_group_name: monitoring +#adopt_label_group_names: +# - "{{ mon_group_name }}" +# - "{{ osd_group_name }}" +# - "{{ rgw_group_name }}" +# - "{{ mds_group_name }}" +# - "{{ nfs_group_name }}" +# - "{{ rbdmirror_group_name }}" +# - "{{ client_group_name }}" +# - "{{ iscsi_gw_group_name }}" +# - "{{ mgr_group_name }}" +# - "{{ rgwloadbalancer_group_name }}" +# - "{{ monitoring_group_name }}" # If configure_firewall is true, then ansible will try to configure the # appropriate firewalling rules so that Ceph daemons can communicate diff --git a/infrastructure-playbooks/cephadm-adopt.yml b/infrastructure-playbooks/cephadm-adopt.yml index bc5d6bd46..3136e5229 100644 --- a/infrastructure-playbooks/cephadm-adopt.yml +++ b/infrastructure-playbooks/cephadm-adopt.yml @@ -361,13 +361,13 @@ when: is_hci | bool - name: manage nodes with cephadm - ipv4 - command: "{{ ceph_cmd }} orch host add {{ ansible_facts['nodename'] }} {{ ansible_facts['all_ipv4_addresses'] | ips_in_ranges(cephadm_mgmt_network.split(',')) | first }} {{ group_names | join(' ') }}" + command: "{{ ceph_cmd }} orch host add {{ ansible_facts['nodename'] }} {{ ansible_facts['all_ipv4_addresses'] | ips_in_ranges(cephadm_mgmt_network.split(',')) | first }} {{ group_names | intersect(adopt_label_group_names) | join(' ') }}" changed_when: false delegate_to: '{{ groups[mon_group_name][0] }}' when: ip_version == 'ipv4' - name: manage nodes with cephadm - ipv6 - command: "{{ ceph_cmd }} orch host add {{ ansible_facts['nodename'] }} {{ ansible_facts['all_ipv6_addresses'] | ips_in_ranges(cephadm_mgmt_network.split(',')) | last | ipwrap }} {{ group_names | join(' ') }}" + command: "{{ ceph_cmd }} orch host add {{ ansible_facts['nodename'] }} {{ ansible_facts['all_ipv6_addresses'] | ips_in_ranges(cephadm_mgmt_network.split(',')) | last | ipwrap }} {{ group_names | intersect(adopt_label_group_names) | join(' ') }}" changed_when: false delegate_to: '{{ groups[mon_group_name][0] }}' when: ip_version == 'ipv6' diff --git a/roles/ceph-defaults/defaults/main.yml b/roles/ceph-defaults/defaults/main.yml index 4e7ed67e7..b69a4a70b 100644 --- a/roles/ceph-defaults/defaults/main.yml +++ b/roles/ceph-defaults/defaults/main.yml @@ -49,6 +49,18 @@ iscsi_gw_group_name: iscsigws mgr_group_name: mgrs rgwloadbalancer_group_name: rgwloadbalancers monitoring_group_name: monitoring +adopt_label_group_names: + - "{{ mon_group_name }}" + - "{{ osd_group_name }}" + - "{{ rgw_group_name }}" + - "{{ mds_group_name }}" + - "{{ nfs_group_name }}" + - "{{ rbdmirror_group_name }}" + - "{{ client_group_name }}" + - "{{ iscsi_gw_group_name }}" + - "{{ mgr_group_name }}" + - "{{ rgwloadbalancer_group_name }}" + - "{{ monitoring_group_name }}" # If configure_firewall is true, then ansible will try to configure the # appropriate firewalling rules so that Ceph daemons can communicate