Properly derive the git_pillar cachedir from the id instead of the URL

Fixes #28257
This commit is contained in:
Erik Johnson 2016-01-27 10:31:47 -06:00
parent 62654ade1d
commit 8b5933fab4

View file

@ -253,7 +253,7 @@ class GitProvider(object):
failhard(self.role)
hash_type = getattr(hashlib, self.opts.get('hash_type', 'md5'))
self.hash = hash_type(self.url).hexdigest()
self.hash = hash_type(self.id).hexdigest()
self.cachedir_basename = getattr(self, 'name', self.hash)
self.cachedir = os.path.join(cache_root, self.cachedir_basename)
if not os.path.isdir(self.cachedir):