mirror of
https://github.com/certbot/certbot.git
synced 2026-06-09 08:42:57 -04:00
Add --dry-run support when getting a new cert
This commit is contained in:
parent
d56d15225e
commit
0db36afa09
1 changed files with 4 additions and 2 deletions
|
|
@ -416,13 +416,15 @@ def _auth_from_domains(le_client, config, domains):
|
|||
elif action == "newcert":
|
||||
# TREAT AS NEW REQUEST
|
||||
lineage = le_client.obtain_and_enroll_certificate(domains)
|
||||
if not lineage:
|
||||
if lineage is False:
|
||||
raise errors.Error("Certificate could not be obtained")
|
||||
|
||||
_report_new_cert(lineage.cert, lineage.fullchain)
|
||||
if lineage is not None:
|
||||
_report_new_cert(lineage.cert, lineage.fullchain)
|
||||
|
||||
return lineage, action
|
||||
|
||||
|
||||
def _avoid_invalidating_lineage(config, lineage, original_server):
|
||||
"Do not renew a valid cert with one from a staging server!"
|
||||
def _is_staging(srv):
|
||||
|
|
|
|||
Loading…
Reference in a new issue