-
-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
Default to logging to stdout/stderr under systemd #6987
Comments
log.mode default will record nothing if you ignore that setting I think. @zeripath |
We can't detect if we're being run by systemd or not very easily - (I think if our parent is pid 0 that's probably the only way). Further people are very particular about logging so overriding them is not really acceptable. However what we could do recommend is that the basic logging config is:
That should at least give us something Edit: my phone keyboard is being really annoying of late. I'm so sorry to keep closing things by mistake. |
Yes, no need to detect systemd, this is purely about documentation. I think we should adjust our What is this |
You can name a logger whatever you like, the mode will default to the name if you don't provide it. The ability to do this was mentioned here #6095 in the Subloggers section and https://docs.gitea.io/en-us/config-cheat-sheet/#log-subsections-log-name-log-name |
I see. Why not just change the default for the
|
It's best to keep stderr for errors only. If you use [log.console] to configure that logger, then if you want to add a console logger for easy debugging then it becomes more difficult. It doesn't really matter I guess - it's supposed to be configurable. |
Ah, so the Generally, I think the logger configuration, while flexible, is a bit too complex for regular users to understand. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions. |
This issue has been automatically closed because of inactivity. You can re-open it if needed. |
We get a number of issues like #6972 with no usable error information because apparently gitea does not log anything to the
stdout
andstderr
when it encounters runtime errors. I'm not sure how these deployments are done, but I assumelog.mode
does not includeconsole
?The text was updated successfully, but these errors were encountered: