Merge pull request #11779 from cachedout/11453-1

Fix #11453
This commit is contained in:
Thomas S Hatch 2014-04-04 15:15:22 -06:00
commit b9ec87cb7b
2 changed files with 9 additions and 0 deletions

View File

@ -1196,6 +1196,12 @@ class AESFuncs(object):
return False
if not salt.utils.verify.valid_id(self.opts, load['id']):
return False
mods = set()
for func in self.mminion.functions.values():
mods.add(func.__module__)
for mod in mods:
sys.modules[mod].__grains__ = load['grains']
pillar = salt.pillar.Pillar(
self.opts,
load['grains'],
@ -1215,6 +1221,8 @@ class AESFuncs(object):
{'grains': load['grains'],
'pillar': data})
)
for mod in mods:
sys.modules[mod].__grains__ = self.opts['grains']
return data
def _minion_event(self, load):

View File

@ -7,6 +7,7 @@ Render the pillar data
import os
import collections
import logging
import copy
# Import salt libs
import salt.loader