Mail directives

listen (mail-core)

Mail server listener; syntax excerpt, other parameters exist.

Formal Syntax & Structure

nginx syntaxnginx
listen address:port [ssl];

Parameters & Attributes

NameTypeDescription
addressaddress:port | port | unix:pathSelect mail listener endpoint; use explicit high loopback port for lab.
sslliteral sslRequire implicit TLS; not the STARTTLS upgrade mode.
proxy_protocolliteral proxy_protocolRequire incoming PROXY metadata (since 1.19.8); restrict listener to trusted peers.
socket_optionsbacklog=number | rcvbuf=size | sndbuf=size | bind | ipv6only=on/off | so_keepalive=... | other supported optionsCheck version and platform availability; not interchangeable with HTTP or stream listener options.

Working Example

Example Snippetnginx
listen 127.0.0.1:19381 ssl;
Nginx Reference