mapper.opts, not self.opts

This commit is contained in:
Joseph Hall 2014-11-20 08:54:52 -07:00 committed by rallytime
parent 473dea47f0
commit 92744e9541

View File

@ -277,7 +277,7 @@ class CloudClient(object):
Query all instance information
'''
mapper = salt.cloud.Map(self._opts_defaults())
self.opts['selected_query_option'] = 'list_nodes_full'
mapper.opts['selected_query_option'] = 'list_nodes_full'
return mapper.map_providers_parallel(query_type)
def select_query(self, query_type='list_nodes_select'):
@ -285,7 +285,7 @@ class CloudClient(object):
Query select instance information
'''
mapper = salt.cloud.Map(self._opts_defaults())
self.opts['selected_query_option'] = 'list_nodes_select'
mapper.opts['selected_query_option'] = 'list_nodes_select'
return mapper.map_providers_parallel(query_type)
def min_query(self, query_type='list_nodes_min'):
@ -293,7 +293,7 @@ class CloudClient(object):
Query select instance information
'''
mapper = salt.cloud.Map(self._opts_defaults())
self.opts['selected_query_option'] = 'list_nodes_min'
mapper.opts['selected_query_option'] = 'list_nodes_min'
return mapper.map_providers_parallel(query_type)
def profile(self, profile, names, vm_overrides=None, **kwargs):
@ -603,7 +603,7 @@ class Cloud(object):
for driver, details in drivers.iteritems():
# If driver has function list_nodes_min, just replace it
# with query param to check existing vms on this driver
# for minimum information, Othwise still use query param.
# for minimum information, Otherwise still use query param.
if 'selected_query_option' not in opts:
if '{0}.list_nodes_min'.format(driver) in self.clouds:
this_query = 'list_nodes_min'