Directive reference
listen
Selects the address, port and protocol for a server.
| Syntax | listen address[:port] [ssl] [http2] [default_server] [reuseport] [backlog=number]; |
|---|---|
| Contexts | serverstream server |
| Default | none |
Behavior
IPv4, bracketed IPv6 and port-only forms are supported. Server selection first groups blocks by listening socket, then applies server_name matching.
Beta note. QUIC/listen ... quic is not implemented in the public beta.
Example
listen 443 ssl default_server;