summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTodd Zullinger <tmz@pobox.com>2008-11-26 10:07:13 -0500
committerTodd Zullinger <tmz@pobox.com>2008-11-26 10:55:42 -0500
commitac857ef91ee4138fa868264115efb72ee8b8c261 (patch)
tree30b5925a63dd380d84590573e42a84faf7d7f4be
parent1ecbc6b8a4bd1a37bd808f9f9830e7884629ca14 (diff)
downloadpuppet-host-package-ac857ef91ee4138fa868264115efb72ee8b8c261.tar.gz
puppet-host-package-ac857ef91ee4138fa868264115efb72ee8b8c261.tar.xz
puppet-host-package-ac857ef91ee4138fa868264115efb72ee8b8c261.zip
Symlink certificates from ca/signed to certs/v0.2
There may be certificates in ca/signed that are not also in certs. Creating symbolic links allows us to use those certificates.
-rwxr-xr-xpuppethost.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/puppethost.py b/puppethost.py
index 3398584..f524c37 100755
--- a/puppethost.py
+++ b/puppethost.py
@@ -185,6 +185,10 @@ class PuppetHost(object):
def files(self):
hostname = self.hostname
ssldir = self.opts['ssldir']
+ cert = '%s/certs/%s.pem' % (ssldir, hostname)
+ casigned = '%s/ca/signed/%s.pem' % (ssldir, hostname)
+ if not os.path.exists(cert) and os.path.exists(casigned):
+ os.symlink(casigned.replace(ssldir, '..'), cert)
return {
'crl': '%s/ca/ca_crl.pem' % ssldir,
'cacert': '%s/certs/ca.pem' % ssldir,