def install(self, bundle): """Persist an ent cert and it's key after splitting it from the bundle.""" self.pre_install(bundle) cert_bundle_writer = Writer() try: key, cert = self.build_cert(bundle) cert_bundle_writer.write(key, cert) self.report.added.append(cert) except Exception, e: self.install_exception(bundle, e)
def install(self, serials, report): br = Writer() exceptions = [] for bundle in self.getCertificatesBySerialList(serials): try: key, cert = self.build(bundle) br.write(key, cert) report.added.append(cert) except Exception, e: log.exception(e) log.error('Bundle not loaded:\n%s\n%s', bundle, e) exceptions.append(e.message)