def renew(config, unused_plugins): """Renew previously-obtained certificates. :param config: Configuration object :type config: interfaces.IConfig :param unused_plugins: List of plugins (deprecated) :type unused_plugins: `list` of `str` :returns: `None` :rtype: None """ if not sys.stdin.isatty(): # Noninteractive renewals include a random delay in order to spread # out the load on the certificate authority servers, even if many # users all pick the same time for renewals. This delay precedes # running any hooks, so that side effects of the hooks (such as # shutting down a web service) aren't prolonged unnecessarily. sleep_time = random.randint(1, 60*8) logger.info("Non-interactive renewal: random delay of %s seconds", sleep_time) time.sleep(sleep_time) try: renewal.handle_renewal_request(config) finally: hooks.run_saved_post_hooks()
def renew(config, unused_plugins): """Renew previously-obtained certificates. :param config: Configuration object :type config: interfaces.IConfig :param unused_plugins: List of plugins (deprecated) :type unused_plugins: `list` of `str` :returns: `None` :rtype: None """ try: renewal.handle_renewal_request(config) finally: hooks.run_saved_post_hooks()
def renew(config, unused_plugins): """Renew previously-obtained certificates.""" try: renewal.handle_renewal_request(config) finally: hooks.run_saved_post_hooks()
def renew(config, unused_plugins): """Renew previously-obtained certificates.""" try: renewal.handle_renewal_request(config) finally: hooks.post_hook(config, final=True)