Comma-separated list of addresses and ports on
which the proxy server should listen for
HTTP/HTTPS traffic.
The proxy server is the public entry point of Kong,
which proxies traffic from your consumers to your
backend services. This value accepts IPv4, IPv6, and
hostnames.
Some suffixes can be specified for each pair:
-
ssl
will require that all connections made
through a particular address/port be made with TLS
enabled.
-
http2
will allow for clients to open HTTP/2
connections to Kong’s proxy server.
-
proxy_protocol
will enable usage of the
PROXY protocol for a given address/port.
-
deferred
instructs to use a deferred accept on
Linux (the TCP_DEFER_ACCEPT socket option).
-
bind
instructs to make a separate bind() call
for a given address:port pair.
-
reuseport
instructs to create an individual
listening socket for each worker process
allowing the Kernel to better distribute incoming
connections between worker processes
-
backlog=N
sets the maximum length for the queue
of pending TCP connections. This number should
not be too small in order to prevent clients
seeing “Connection refused” error connecting to
a busy Kong instance.
Note: on Linux, this value is limited by the
setting of net.core.somaxconn
Kernel parameter.
In order for the larger backlog
set here to take
effect it is necessary to raise
net.core.somaxconn
at the same time to match or
exceed the backlog
number set.
-
ipv6only=on|off
whether an IPv6 socket listening
on a wildcard address [::] will accept only IPv6
connections or both IPv6 and IPv4 connections
- so_keepalive=on|off|[keepidle]:[keepintvl]:[keepcnt]
configures the “TCP keepalive” behavior for the listening
socket. If this parameter is omitted then the operating
system’s settings will be in effect for the socket. If it
is set to the value “on”, the SO_KEEPALIVE option is turned
on for the socket. If it is set to the value “off”, the
SO_KEEPALIVE option is turned off for the socket. Some
operating systems support setting of TCP keepalive parameters
on a per-socket basis using the TCP_KEEPIDLE, TCP_KEEPINTVL,
and TCP_KEEPCNT socket options.
This value can be set to off
, thus disabling
the HTTP/HTTPS proxy port for this node.
If stream_listen is also set to off
, this enables
‘control-plane’ mode for this node
(in which all traffic proxying capabilities are
disabled). This node can then be used only to
configure a cluster of Kong
nodes connected to the same datastore.
Example:
proxy_listen = 0.0.0.0:443 ssl, 0.0.0.0:444 http2 ssl
See http://nginx.org/en/docs/http/ngx_http_core_module.html#listen
for a description of the accepted formats for this
and other *_listen
values.
See https://www.nginx.com/resources/admin-guide/proxy-protocol/
for more details about the proxy_protocol
parameter.
Not all *_listen
values accept all formats
specified in nginx’s documentation.