diff --git a/src/yunohost/certificate.py b/src/yunohost/certificate.py index f213fd914..170e5eb3b 100644 --- a/src/yunohost/certificate.py +++ b/src/yunohost/certificate.py @@ -483,6 +483,10 @@ def _check_acme_challenge_configuration(domain): def _fetch_and_enable_new_certificate(domain, staging=False, no_checks=False): + + if not os.path.exists(ACCOUNT_KEY_FILE): + _generate_account_key() + # Make sure tmp folder exists logger.debug("Making sure tmp folders exists...")