-
Notifications
You must be signed in to change notification settings - Fork 572
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
download does not work #229
Comments
It just happen to me as well - I identified the issue and made a fix that seems to be working just fine ;) I hope it helps |
We just encountered the same issue which was due to our nodejs/expressjs webserver taking a moment to reload and pickup the challenge after it was written to the disk. In that time the request from acme_tiny was attempted and resulted in a failure. Adding a small delay on line 138, inbetween writing the challenge and attempting to retrieve it fixed the issue: wellknown_path = os.path.join(acme_dir, token)
with open(wellknown_path, "w") as wellknown_file:
wellknown_file.write(keyauthorization)
time.sleep(3) # <=== NEW ADDITION
# check that the file is in place
try:
wellknown_url = "http://{0}/.well-known/acme-challenge/{1}".format(domain, token)
assert (disable_check or _do_request(wellknown_url)[0] == keyauthorization)
except (AssertionError, ValueError) as e:
raise ValueError("Wrote file to {0}, but couldn't download {1}: {2}".format(wellknown_path, wellknown_url, e)) 3 seconds may be excessive but better safe than sorry (and perhaps for larger webapps with alot of initialization logic this wouldn't be enough). Thoughts on adding something like this to the codebase (perhaps with a configurable delay)? I can send a PR if it is acceptable |
hi
I've implemented this script like https://xdeb.org/post/2016/02/09/lets-encrypt-my-servers-with-acme-tiny/ with a dedicated challenges folder for all sites and a link folder on OS-level (in stead of website configuration).
for 2 of my 3 sites the update of the cert works but for 1 I get the error:
when I check with ssh, I see the file and I can download it with firefox (content = the name of the file + '.' and suffix).
it is on debian 9 and Apache/2.4.25 (Debian)
any ideas?
Mario
The text was updated successfully, but these errors were encountered: