Do not call updaters and deployers when run with --dry-run (#6038)

When Certbot is run with --dry-run, skip running GenericUpdater and RenewDeployer interface methods.

This PR also makes the parameter order of updater.run_generic_updaters and updater.run_renewal_deployer consistent.

Fixes #5927

* Do not call updaters and deployers when run with --dry-run

* Use ConfigTestCase instead of mocking config objects manually
This commit is contained in:
Joona Hoikkala
2018-05-26 08:31:23 -07:00
committed by Brad Warren
parent e48c653245
commit 9f6b147d6f
5 changed files with 41 additions and 23 deletions
+2 -2
View File
@@ -431,8 +431,8 @@ def handle_renewal_request(config):
renew_skipped.append("%s expires on %s" % (renewal_candidate.fullchain,
expiry.strftime("%Y-%m-%d")))
# Run updater interface methods
updater.run_generic_updaters(lineage_config, plugins,
renewal_candidate)
updater.run_generic_updaters(lineage_config, renewal_candidate,
plugins)
except Exception as e: # pylint: disable=broad-except
# obtain_cert (presumably) encountered an unanticipated problem.