mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #45751 from rallytime/bp-45588
Back-port #45588 to 2017.7
This commit is contained in:
commit
454ed23f62
1 changed files with 3 additions and 1 deletions
|
@ -298,7 +298,7 @@ class MasterPillarUtil(object):
|
|||
cached minion data on the master, or by fetching the grains
|
||||
directly on the minion.
|
||||
|
||||
By default, this function tries hard to get the pillar data:
|
||||
By default, this function tries hard to get the grains data:
|
||||
- Try to get the cached minion grains if the master
|
||||
has minion_data_cache: True
|
||||
- If the grains data for the minion is cached, use it.
|
||||
|
@ -307,6 +307,8 @@ class MasterPillarUtil(object):
|
|||
'''
|
||||
minion_grains = {}
|
||||
minion_ids = self._tgt_to_list()
|
||||
if not minion_ids:
|
||||
return {}
|
||||
if any(arg for arg in [self.use_cached_grains, self.grains_fallback]):
|
||||
log.debug('Getting cached minion data.')
|
||||
cached_minion_grains, cached_minion_pillars = self._get_cached_minion_data(*minion_ids)
|
||||
|
|
Loading…
Add table
Reference in a new issue