mirror of
https://github.com/certbot/certbot.git
synced 2026-06-07 15:52:08 -04:00
get_cert_file -> get_cert_path.
This commit is contained in:
parent
1bc9e7cb64
commit
3e2d1c8abc
4 changed files with 5 additions and 5 deletions
|
|
@ -145,7 +145,7 @@ class Dvsni(object):
|
|||
if idx is not None:
|
||||
self.indices.append(idx)
|
||||
|
||||
def get_cert_file(self, achall):
|
||||
def get_cert_path(self, achall):
|
||||
"""Returns standardized name for challenge certificate.
|
||||
|
||||
:param achall: Annotated DVSNI challenge.
|
||||
|
|
@ -166,7 +166,7 @@ class Dvsni(object):
|
|||
def _setup_challenge_cert(self, achall, s=None):
|
||||
# pylint: disable=invalid-name
|
||||
"""Generate and write out challenge certificate."""
|
||||
cert_path = self.get_cert_file(achall)
|
||||
cert_path = self.get_cert_path(achall)
|
||||
# Register the path before you write out the file
|
||||
self.configurator.reverter.register_file_creation(True, cert_path)
|
||||
|
||||
|
|
|
|||
|
|
@ -164,7 +164,7 @@ class DvsniTest(unittest.TestCase):
|
|||
|
||||
self.assertTrue(m_open.called)
|
||||
self.assertEqual(
|
||||
m_open.call_args[0], (self.sni.get_cert_file(achall), "w"))
|
||||
m_open.call_args[0], (self.sni.get_cert_path(achall), "w"))
|
||||
self.assertEqual(m_open().write.mock_calls[0][1][0], "pem")
|
||||
self.assertEqual(m_open().write.mock_calls[1][1][0],
|
||||
achall.key.key.private_bytes())
|
||||
|
|
|
|||
|
|
@ -142,6 +142,6 @@ class ApacheDvsni(common.Dvsni):
|
|||
return self.VHOST_TEMPLATE.format(
|
||||
vhost=ips, server_name=achall.nonce_domain,
|
||||
ssl_options_conf_path=self.configurator.parser.loc["ssl_options"],
|
||||
cert_path=self.get_cert_file(achall),
|
||||
cert_path=self.get_cert_path(achall),
|
||||
key_path=self.get_key_path(achall),
|
||||
document_root=document_root).replace("\n", os.linesep)
|
||||
|
|
|
|||
|
|
@ -140,7 +140,7 @@ class NginxDvsni(common.Dvsni):
|
|||
self.configurator.config.work_dir, 'access.log')],
|
||||
['error_log', os.path.join(
|
||||
self.configurator.config.work_dir, 'error.log')],
|
||||
['ssl_certificate', self.get_cert_file(achall)],
|
||||
['ssl_certificate', self.get_cert_path(achall)],
|
||||
['ssl_certificate_key', self.get_key_path(achall)],
|
||||
[['location', '/'], [['root', document_root]]]])
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue