add docker setup
This commit is contained in:
@@ -25,9 +25,11 @@ var defaults = []struct {
|
||||
{"Server", []defaultKV{
|
||||
{"", "", "Server configuration for SMTP ports and hostname"},
|
||||
{"", "", "Plain SMTP port for internal/whitelisted IPs"},
|
||||
{"SMTP_PORT", "4025", ""},
|
||||
{"", "", "TLS SMTP port for authenticated users"},
|
||||
{"SMTP_TLS_PORT", "40465", ""},
|
||||
{"", "", "(standard port 25 — the process needs CAP_NET_BIND_SERVICE or root to bind"},
|
||||
{"", "", "it directly; not an issue in the Docker deployment, which runs as root)"},
|
||||
{"SMTP_PORT", "25", ""},
|
||||
{"", "", "Direct/implicit-TLS SMTP port for authenticated users (like SMTPS, not STARTTLS)"},
|
||||
{"SMTP_TLS_PORT", "465", ""},
|
||||
{"", "", "Server hostname for HELO/EHLO identification"},
|
||||
{"HOSTNAME", "mail.example.com", ""},
|
||||
{"", "", "Override HELO hostname"},
|
||||
@@ -112,9 +114,9 @@ var defaults = []struct {
|
||||
{"IMAP", []defaultKV{
|
||||
{"", "", "IMAP server configuration for mailbox retrieval (Thunderbird, etc.)"},
|
||||
{"", "", "Plain IMAP port (STARTTLS not offered, matching the SMTP plain-port design)"},
|
||||
{"IMAP_PORT", "1143", ""},
|
||||
{"IMAP_PORT", "143", ""},
|
||||
{"", "", "Implicit-TLS IMAP port (IMAPS)"},
|
||||
{"IMAP_TLS_PORT", "1993", ""},
|
||||
{"IMAP_TLS_PORT", "993", ""},
|
||||
}},
|
||||
{"Mailstore", []defaultKV{
|
||||
{"", "", "Local mailbox storage configuration"},
|
||||
|
||||
@@ -17,8 +17,8 @@ func TestGenerateAndLoadRoundTrip(t *testing.T) {
|
||||
if _, err := os.Stat(path); err != nil {
|
||||
t.Fatalf("settings.ini was not written: %v", err)
|
||||
}
|
||||
if got := cfg.Section("Server").Key("SMTP_PORT").String(); got != "4025" {
|
||||
t.Errorf("SMTP_PORT = %q, want 4025", got)
|
||||
if got := cfg.Section("Server").Key("SMTP_PORT").String(); got != "25" {
|
||||
t.Errorf("SMTP_PORT = %q, want 25", got)
|
||||
}
|
||||
if got := cfg.Section("Attachments").Key("attachments_path").String(); got == "" {
|
||||
t.Error("Attachments.attachments_path default is missing (the approved bug fix)")
|
||||
@@ -29,8 +29,8 @@ func TestGenerateAndLoadRoundTrip(t *testing.T) {
|
||||
if err != nil {
|
||||
t.Fatalf("Load (existing): %v", err)
|
||||
}
|
||||
if got := cfg2.Section("Server").Key("SMTP_PORT").String(); got != "4025" {
|
||||
t.Errorf("second Load: SMTP_PORT = %q, want 4025", got)
|
||||
if got := cfg2.Section("Server").Key("SMTP_PORT").String(); got != "25" {
|
||||
t.Errorf("second Load: SMTP_PORT = %q, want 25", got)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user