From 78b6550f9b9f59772a7a4b6f0b2a53c84e476e9f Mon Sep 17 00:00:00 2001 From: Nicolas Limage Date: Mon, 23 Jun 2014 18:24:33 +0200 Subject: [PATCH] fixes potential ext_pillar line mismatches --- salt/pillar/git_pillar.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/salt/pillar/git_pillar.py b/salt/pillar/git_pillar.py index fa69116887..9fcf392ae6 100644 --- a/salt/pillar/git_pillar.py +++ b/salt/pillar/git_pillar.py @@ -102,9 +102,9 @@ class GitPillar(object): self.working_dir = '' self.repo = None - needle = '{0} {1}'.format(self.branch, self.rp_location) for idx, opts_dict in enumerate(self.opts['ext_pillar']): - if opts_dict.get('git', '').startswith(needle): + lopts = opts_dict.get('git', '').split() + if len(lopts) >= 2 and lopts[:2] == [self.branch, self.rp_location]: rp_ = os.path.join(self.opts['cachedir'], 'pillar_gitfs', str(idx))