simp_le
simp_le copied to clipboard
Keep challenge files in case of authorization error
@zenhack I thought it might be useful for troubleshooting purpose to do a simple adjustment on 212acd3efa6090641845bc08b63a512b082e0cb0 and have simp_le remove challenge files only on successful domain authorization rather than wether the authorization succeed or not. Do you agree ?
Have you found yourself wanting this when debugging?
It sounds like a plausible use case, but I've never found myself digging through the challenge files, so I want to make sure we're not adding functionality that no one is actually going to use.
Not while using simp_le in standalone, but with letsencrypt-nginx-proxy-companion it's quite common to curl the challenge file in order to troubleshoot a failed domain validation.
This comment in particular made me think that people are probably going to look after the challenge file only when a validation fails and might draw wrong conclusions from the fact that the file has been deleted.
I recognize that the challenge file itself and its content are completely irrelevant to the troubleshooting process, you might as well echo 'Hello, world' > hello-world on the webroot and try to curl this file instead.
Ok, just wanted to sanity check that it's really useful; I'm convinced of that now.
My other concern is about generating garbage in the challange directory. It would be nice to avoid littering the directory with failed attempts.
Agreed, just keeping every challenge file that the validation server fails to get kind of undo https://github.com/zenhack/simp_le/commit/212acd3efa6090641845bc08b63a512b082e0cb0.
Do you think this (the challenge file mentioned in the error message being automatically deleted) might be an issue for the standalone simp_le too or is it more specific to project that use it like letsencrypt-nginx-proxy-companion ?
Quoting Nicolas Duchon (2017-12-03 15:19:14)
Do you think this (the challenge file mentioned in the error message being automatically deleted) might be an issue for the standalone simp_le too or is it more specific to project that use it like letsencrypt-nginx-proxy-companion ?
Like I said, I've never really found myself wanting this. Though, I've not had simp_le fail very often either.
My inclination is to leave things as they are unless it becomes clear that it's a real problem. Maybe we could just log the fact that we're deleting those files at info level instead of debug?
Maybe we could just log the fact that we're deleting those files at info level instead of debug?
I'd say that would be enough.