diff options
author | Adrian Likins <alikins@redhat.com> | 2008-09-01 22:42:47 -0400 |
---|---|---|
committer | Adrian Likins <alikins@redhat.com> | 2008-09-01 22:42:47 -0400 |
commit | 01e4a97116dbf0518b1f51e4a42f9756919ef64b (patch) | |
tree | 440f9f16065479d2083fca2cf416011f2b5e4bab /func/overlord | |
parent | 5844ba440ea481813bbfd2ae1caf04ea4efb6826 (diff) | |
download | func-01e4a97116dbf0518b1f51e4a42f9756919ef64b.tar.gz func-01e4a97116dbf0518b1f51e4a42f9756919ef64b.tar.xz func-01e4a97116dbf0518b1f51e4a42f9756919ef64b.zip |
remove any unneeded /'s from the cert path to fix ticket #53
"Trailing slash in certmaster.conf confuses glob function"
Diffstat (limited to 'func/overlord')
-rwxr-xr-x | func/overlord/client.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/func/overlord/client.py b/func/overlord/client.py index 9e4b0dc..36416ad 100755 --- a/func/overlord/client.py +++ b/func/overlord/client.py @@ -114,7 +114,10 @@ class Minions(object): #For example spec = "@home_group;*" will give lots of duplicates as a result if not cert in self.all_certs: self.all_certs.append(cert) - host = cert.replace(self.config.certroot,"")[1:-(len(self.config.cert_extension) + 1)] + # use basename to trim off any excess /'s, fix + # ticket #53 "Trailing slash in certmaster.conf confuses glob function + certname = os.path.basename(cert.replace(self.config.certroot, "")) + host = certname[:(len(self.config.cert_extension) - 1)] self.all_hosts.append(host) def get_all_hosts(self): |