Use 'roles:' instead of 'role:' in mon search so that expanded runlists are included in the search (i.e. you'll be able to to include the ceph-mon role in another role).
This commit is contained in:
parent
ef9c91bebd
commit
641f460311
@ -9,11 +9,11 @@ def get_mon_nodes(extra_search=nil)
|
||||
if is_crowbar?
|
||||
mon_roles = search(:role, 'name:crowbar-* AND run_list:role\[ceph-mon\]')
|
||||
if not mon_roles.empty?
|
||||
search_string = mon_roles.map { |role_object| "role:"+role_object.name }.join(' OR ')
|
||||
search_string = mon_roles.map { |role_object| "roles:"+role_object.name }.join(' OR ')
|
||||
search_string = "(#{search_string}) AND ceph_config_environment:#{node['ceph']['config']['environment']}"
|
||||
end
|
||||
else
|
||||
search_string = "role:ceph-mon AND chef_environment:#{node.chef_environment}"
|
||||
search_string = "roles:ceph-mon AND chef_environment:#{node.chef_environment}"
|
||||
end
|
||||
|
||||
if not extra_search.nil?
|
||||
|
Loading…
x
Reference in New Issue
Block a user