Commit c9403ec6 authored by Rafael Monnerat's avatar Rafael Monnerat

LinkBinary is not need for apache

parent 0c513667
...@@ -58,7 +58,6 @@ class Recipe(BaseSlapRecipe): ...@@ -58,7 +58,6 @@ class Recipe(BaseSlapRecipe):
site_url = self.installFrontendApache(ip=self.getGlobalIPv6Address(), site_url = self.installFrontendApache(ip=self.getGlobalIPv6Address(),
port=8080, key=key, certificate=certificate) port=8080, key=key, certificate=certificate)
self.linkBinary()
self.setConnectionDict(dict(site_url=site_url, )) self.setConnectionDict(dict(site_url=site_url, ))
return self.path_list return self.path_list
...@@ -85,28 +84,6 @@ class Recipe(BaseSlapRecipe): ...@@ -85,28 +84,6 @@ class Recipe(BaseSlapRecipe):
dict(file_list=' '.join(['"'+q+'"' for q in log_file_list]), dict(file_list=' '.join(['"'+q+'"' for q in log_file_list]),
postrotate=postrotate_script, olddir=self.logrotate_backup))) postrotate=postrotate_script, olddir=self.logrotate_backup)))
def linkBinary(self):
"""Links binaries to instance's bin directory for easier exposal"""
for linkline in self.options.get('link_binary_list', '').splitlines():
if not linkline:
continue
target = linkline.split()
if len(target) == 1:
target = target[0]
path, linkname = os.path.split(target)
else:
linkname = target[1]
target = target[0]
link = os.path.join(self.bin_directory, linkname)
if os.path.lexists(link):
if not os.path.islink(link):
raise zc.buildout.UserError(
'Target link already %r exists but it is not link' % link)
os.unlink(link)
os.symlink(target, link)
self.logger.debug('Created link %r -> %r' % (link, target))
self.path_list.append(link)
def requestCertificate(self, name): def requestCertificate(self, name):
hash = hashlib.sha512(name).hexdigest() hash = hashlib.sha512(name).hexdigest()
key = os.path.join(self.ca_private, hash + self.ca_key_ext) key = os.path.join(self.ca_private, hash + self.ca_key_ext)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment