mirror of
https://github.com/axllent/mailpit.git
synced 2026-04-26 00:35:51 +03:00
[GH-ISSUE #338] Feature Request - Add option to Control Message Retention by Age (TTL) #228
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#228
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 @alexkved on GitHub (Jul 30, 2024).
Original GitHub issue: https://github.com/axllent/mailpit/issues/338
Description
Currently, Mailpit allows users to limit the maximum number of email messages stored using the
MP_MAX_MESSAGESoption. However, some users would prefer to control the retention of messages based on their age. For example, automatically deleting messages older than a specified number of hours or days.Proposed Solution
Introduce a new option
MP_MAX_MESSAGE_AGEthat specifies the maximum age of messages to be retained in Mailpit. Messages older than this age should be automatically deleted.Option:
MP_MAX_MESSAGE_AGE: Specifies the maximum age of messages in hours or days. For example, 72h to retain messages for 72 hours or 3d for 3 days.Benefits
Example Usage:
@axllent commented on GitHub (Jul 30, 2024):
Thanks for your suggestion @alexkved, this makes sense to me. I do not have an ETA as I'm working on another big task right now, but I'll add this to my "TODO" list 👍
@alexkved commented on GitHub (Jul 31, 2024):
Thank you for considering this feature request. We appreciate your time and effort in reviewing it, and we look forward to any updates you might have on this in the future.
@axllent commented on GitHub (Aug 6, 2024):
This feature has been released in v1.20.0. Please see the release notes and linked documentation, and let me know if this works for you? Thanks.
@alexkved commented on GitHub (Aug 7, 2024):
@axllent , thank you very much for your effort. It works like a charme.
@axllent commented on GitHub (Aug 7, 2024):
That's great to hear, thanks for the feedback!