A CLI-first git forge.

cli forge git self-hosted

https://gitbay.org

Commit b8b7c3b111

b8b7c3b111678afc51f3595d673d9a3ac7c3c884

parent: 1364cf765d

Verified · cmc

cmc <hello@cleberg.net> · 2026-08-24T15:12:52Z

mail: STARTTLS needs a ServerName

StartTLS(nil) fails against any real relay; pass the SMTP host name.
Unexposed by the e2e fake, which does not advertise STARTTLS.
internal/mail/mail.go +2 −1
@@ -4,6 +4,7 @@
44 package mail
55
66 import (
7 "crypto/tls"
78 "fmt"
89 "net"
910 "net/smtp"
@@ -35,7 +36,7 @@ func Send(cfg config.Config, to, subject, body string) error {
3536 }
3637 defer c.Close()
3738 if ok, _ := c.Extension("STARTTLS"); ok {
38 if err := c.StartTLS(nil); err != nil {
39 if err := c.StartTLS(&tls.Config{ServerName: hostname}); err != nil {
3940 return fmt.Errorf("starttls: %w", err)
4041 }
4142 }