On Tue, Feb 14, 2017 at 04:09:10PM +0800, he.hailo...@zte.com.cn wrote:
> now I understand the duplicate listen ports configured in the http
> block can be used to implement virtual hosts.
>
>
> but what's the purpose to allow this in the stream block? in my
> practise (with 1.9.15.1), nginx will
replying, please edit your Subject line so it is more specific
than "Re: Contents of nginx digest..."
Today's Topics:
1. RE: having nginx listen the same port more than once
(Reinis Rozitis)
2. Apache to nginx (Daniel)
3. Re: having nginx listen the same port more
at
nginx-ow...@nginx.org
When replying, please edit your Subject line so it is more specific
than "Re: Contents of nginx digest..."
Today's Topics:
1. RE: having nginx listen the same port more than once
(Reinis Rozitis)
2. Apache to nginx (Daniel)
3. Re: having ng
Assuming a configuration with multiple similar 'listen' and
'server_name' statements, only the first one will work:
server {
listen 9090;
return 404;
server_name example.com;
}
server {
listen 9090;
return 403;
server_name example.com;
> I observe that the nginx runs with no error if there are duplicate listen
> ports configured in the http server block or stream server block.
is this behavior as expected?
That is how every webserver capable of name based virtual hosts works.
So yes it's normal and expected.
> and if a
Hi,
I observe that the nginx runs with no error if there are duplicate listen ports
configured in the http server block or stream server block.
is this behavior as expected? and if a request comes at such a port, which
server would serve this request, by radomly or round-robin?
Hello!
On Mon, Jan 09, 2017 at 11:01:40AM +0800, he.hailo...@zte.com.cn wrote:
> I observe that the nginx runs with no error if there are
> duplicate listen ports configured in the http server block or
> stream server block.
>
> is this behavior as expected? and if a request comes at such a
Hi,
I observe that the nginx runs with no error if there are duplicate listen ports
configured in the http server block or stream server block.
is this behavior as expected? and if a request comes at such a port, which
server would serve this request, by radomly or round-robin?
Thanks,