mirror of
https://github.com/axllent/mailpit.git
synced 2026-04-26 08:45:54 +03:00
[GH-ISSUE #246] Feature request: Configuration of logging #160
Labels
No labels
awaiting feedback
bug
docker
documentation
enhancement
github_actions
invalid
pull-request
question
stale
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/mailpit#160
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @we3geeks on GitHub (Feb 4, 2024).
Original GitHub issue: https://github.com/axllent/mailpit/issues/246
Consider adding configuration options to have logging go to a file, with the location and name of the file also configurable.
I've used Mailpit through Homebrew and can do this as part of the startup command with redirection of stdout to a file of my choice. I've switched to running Mailpit via Docker with the mail database file on a Docker-mounted volume; I'd like to have the logging output go to a file on that same Docker-mounted volume.
@axllent commented on GitHub (Feb 4, 2024):
Thanks for the suggestion, I am sure this can be added as a new feature. When you say "options" (plural), what options other than a file name are you suggesting?
In the interim, docker logs can be viewed with
docker logs <container>, not to mention that you can probably redirect Mailpit logs to a file within docker too simply by adding that to your docker commands.@we3geeks commented on GitHub (Feb 5, 2024):
Apologies; poor choice of wording on my part. Having an option to specify a file with path (similar to the mail database option) would be sufficient.
@axllent commented on GitHub (Feb 5, 2024):
@we3geeks Awesome, thanks for the clarification - I'll see what I can do 👍
@axllent commented on GitHub (Feb 5, 2024):
I've added this feature in v1.13.2 (using
--log-file <filepath>or theMP_LOG_FILE=<filepath>environment variable). The log formatting is somewhat different to the default stdout logging, but this format makes more sense for a physical logfile.Please let me know if this works for you?
@we3geeks commented on GitHub (Feb 6, 2024):
Looks great! Thanks for the quick turnaround on this.
@axllent commented on GitHub (Feb 6, 2024):
Excellent, you're welcome. I'll take that as "it's tested and working" and close this, however feel free to re-open if there is an issue.
@we3geeks commented on GitHub (Feb 6, 2024):
Yes, tested and working as expected.