Welcome! Log In Create A New Profile

Advanced

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev
February 04, 2014 09:33AM
On Monday 03 February 2014 11:48:41 Josh Stratton wrote:
> > or to the first one in the configuration if there is no such
> > parameter.
>
> As if all the server blocks are configured together? That sounds really
> strange to me, that one server block could be the default for another
> server block.

They all are configured together since they share the same address:port pair.
The only separation that server can make is based on requested host, but what
if there is no matches among configured server names? Then nginx picks one
based on a simple rule I already mentioned.

And there is no magic in placing them in different configuration files (in fact,
that "sites-available" thing is just a debian way of splitting web server
configuration), they could be configured in one file as well.


>
> # rgrep default_server /etc/nginx/
> /etc/nginx/sites-available/strattonbrazil.com: #listen [::]:80
> default_server ipv6only=on;
> /etc/nginx/sites-available/morebearsmore.com: #listen [::]:80
> default_server ipv6only=on;

Note, that you have "default_server" for IPv6 only, but your listen directives
for IPv4 haven't got this parameter.

wbr, Valentin V. Bartenev

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Josh Stratton February 04, 2014 09:33AM

Re: server blocks configured, but getting "hello world" of nginx

Valentin V. Bartenev February 04, 2014 09:33AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 176
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready