mirror of
https://github.com/jhillyerd/inbucket.git
synced 2025-12-17 17:47:03 +00:00
Begin work on message retention
- Refactor datastore such that we have a FileDataStore that implements the DataStore interface. - Add in missing SMTP configuration options: max recips, max idle, max message size - Add retention options to config
This commit is contained in:
@@ -10,7 +10,7 @@ import (
|
||||
type Context struct {
|
||||
Vars map[string]string
|
||||
Session *sessions.Session
|
||||
DataStore *smtpd.DataStore
|
||||
DataStore smtpd.DataStore
|
||||
}
|
||||
|
||||
func (c *Context) Close() {
|
||||
@@ -20,7 +20,7 @@ func (c *Context) Close() {
|
||||
func NewContext(req *http.Request) (*Context, error) {
|
||||
vars := mux.Vars(req)
|
||||
sess, err := sessionStore.Get(req, "inbucket")
|
||||
ds := smtpd.NewDataStore()
|
||||
ds := smtpd.NewFileDataStore()
|
||||
ctx := &Context{
|
||||
Vars: vars,
|
||||
Session: sess,
|
||||
|
||||
Reference in New Issue
Block a user