Feature Request: Add logger.startup.MODE for Dedicated Startup Log Configuration #13077

Open
opened 2025-11-02 10:29:34 -06:00 by GiteaMirror · 0 comments
Owner

Originally created by @anonsaber on GitHub (May 31, 2024).

Feature Description

Hello Gitea Maintainers and Community,

I hope everyone is doing great and enjoying some quality time with their code! I'm here to suggest a small but potentially significant improvement to the Gitea logging system.

Current Logging Configuration: As we know, Gitea already supports comprehensive logging configurations via the app.ini file, which is absolutely fantastic. Here’s a snippet of the current setup:

[log]
MODE = file
LEVEL = Info
logger.router.MODE = file
logger.access.MODE = file
logger.xorm.MODE = file
STACKTRACE_LEVEL = None
ENABLE_SSH_LOG = true
ROOT_PATH = /data/gitea/log

Suggested Feature: While this configuration provides great coverage, it seems we're missing a specific option for managing startup logs. During the startup phase, Gitea logs valuable information that could be better managed if directed to a dedicated file. Hence, I propose we introduce a new logging directive:

logger.startup.MODE = file

Benefits: This feature would allow users to redirect startup logs to a specific file, thus keeping the console cleaner and making log management more streamlined. It would be particularly useful for debugging startup issues without sifting through other log types.

Implementation Consideration: This could potentially be a straightforward addition to the logging configuration section, handling startup logs similarly to how logger.router or logger.access are configured.

I believe this enhancement will make log management in Gitea even more robust and user-friendly. Looking forward to hearing your thoughts and any further suggestions on this!

Screenshots

No response

Originally created by @anonsaber on GitHub (May 31, 2024). ### Feature Description Hello Gitea Maintainers and Community, I hope everyone is doing great and enjoying some quality time with their code! I'm here to suggest a small but potentially significant improvement to the Gitea logging system. Current Logging Configuration: As we know, Gitea already supports comprehensive logging configurations via the app.ini file, which is absolutely fantastic. Here’s a snippet of the current setup: ``` [log] MODE = file LEVEL = Info logger.router.MODE = file logger.access.MODE = file logger.xorm.MODE = file STACKTRACE_LEVEL = None ENABLE_SSH_LOG = true ROOT_PATH = /data/gitea/log ``` Suggested Feature: While this configuration provides great coverage, it seems we're missing a specific option for managing startup logs. During the startup phase, Gitea logs valuable information that could be better managed if directed to a dedicated file. Hence, I propose we introduce a new logging directive: ``` logger.startup.MODE = file ``` Benefits: This feature would allow users to redirect startup logs to a specific file, thus keeping the console cleaner and making log management more streamlined. It would be particularly useful for debugging startup issues without sifting through other log types. Implementation Consideration: This could potentially be a straightforward addition to the logging configuration section, handling startup logs similarly to how logger.router or logger.access are configured. I believe this enhancement will make log management in Gitea even more robust and user-friendly. Looking forward to hearing your thoughts and any further suggestions on this! ### Screenshots _No response_
GiteaMirror added the type/proposal label 2025-11-02 10:29:34 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#13077