WithTLSPortPolicy calls SetTLSPortPolicy, which checks `c.port == DefaultPort`
(25) to decide whether the port was explicitly set or left as default. When a
user configures port 25 — common for internal relay hosts that accept plaintext
SMTP — the guard condition evaluates true and the library silently overrides the
port to 587 (DefaultPortTLS) with a fallback to 25.
This causes a two-stage failure in environments where port 587 is unreachable:
1. The primary dial to host:587 blocks for the full 15-second connection
timeout (go-mail DefaultTimeout) waiting on a firewalled port.
2. The fallback dial to host:25 fires with an already-expired context,
producing a misleading "lookup <host>: i/o timeout" DNS error rather
than the actual root cause (port 587 unreachable).
The previous mail library (gopkg.in/mail.v2) used the port value directly
without any policy-based override, so this regression surfaced only after
migrating to github.com/wneessen/go-mail.
WithTLSPolicy applies the same STARTTLS negotiation semantics (NoTLS or
TLSOpportunistic) without mutating the port, which is the correct choice
when the caller has already provided an explicit port via WithPort.
* Support multiple attachments
* Support single attachment syntax in addition to multiple
* Re-add import Goland removed while optimizing imports for me.
* Refactor plugin to be compatible with Drone 0.5
* Add vendor files
* Re-add logo.svg, make loading environment from .env file optional, and use drone-go/template
* Fix README
* Fix issue with date formatting, update the DOCS, and improve types
* Add working directory and volume mount to README example