Merge pull request #13149 from unprofession-al/backport_fix_jsonfile_fact_caching_connection

Backport of the jsonfile cache fix for filepath substitution
This commit is contained in:
James Cammarata 2015-11-13 08:45:17 -05:00
commit ce77d2fa76

View file

@ -37,7 +37,7 @@ class CacheModule(BaseCacheModule):
self._timeout = float(C.CACHE_PLUGIN_TIMEOUT) self._timeout = float(C.CACHE_PLUGIN_TIMEOUT)
self._cache = {} self._cache = {}
self._cache_dir = C.CACHE_PLUGIN_CONNECTION # expects a dir path self._cache_dir = os.path.expandvars(os.path.expanduser(C.CACHE_PLUGIN_CONNECTION)) # expects a dir path
if not self._cache_dir: if not self._cache_dir:
utils.exit("error, fact_caching_connection is not set, cannot use fact cache") utils.exit("error, fact_caching_connection is not set, cannot use fact cache")