-
Notifications
You must be signed in to change notification settings - Fork 60
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
Silent mode #8
Comments
This is technically already possible, since the messages are sent to screen via logger. If you check the "Custom Logging" section at https://github.com/do-know/Crypt-LE, there is an example of log configuration file (used with -log-config option) - you can specify a different log level (WARN or ERROR for example instead of DEBUG). However an option to reduce the logging level without the custom file might be introduced at some point too. |
Yes, I noted that. Writing the config file just feels extra work, when an option/flag could do. My point is that when the output is noisy I get an email from the cron job every time. I'd like to recieve one only when there's something to worry about. Currently I'm using the config file. |
Option would make sense indeed. From your usage experience, would you rather had an option that suppresses both info messages and warnings, or only info messages? For example, the warning about not being able to pull the issuer's certificate might be important (depending on how you work with the certificates later on). |
I think I'd like to see warnings. Maybe the best way would be --loglevel=WARNING or something that could use Log4Perl easy init with the given loglevel. Then user could easily set the level that he wants. |
With --debug switch already there specifying the level explicitly might get a bit confusing, but I'll see to adding either something like that or just a specific silent/quiet option for the next version. |
Update: Version 0.24 is going to CPAN today. Apart from other changes, it now supports '--quiet' switch that forces log level to ERROR. Note that the client does not have too many warnings and the few which are there should not be impacting the workflow normally, so both info and warnings will get suppressed if that option is used. Using loglevel option might be rather confusing for inexperienced users, while for the experienced ones log-config gives very flexible way to re-configure logging to their liking. Once on CPAN, the code will also go to GitHub, Docker Hub, and will be released as Windows binaries. |
Implemented in v0.24. |
Please add silent mode where it's easy to configure renew to be completely silent unless it fails for some reason.
The text was updated successfully, but these errors were encountered: