server_name behaviour

Ensiferous nginx-forum at nginx.us
Mon Sep 13 22:47:58 MSD 2010


Hi

A couple of us in the IRC channel are keeping the wiki updated and we've
come across some inconsistent behaviour with server_name.

The wiki currently states here:
http://wiki.nginx.org/NginxHttpCoreModule#server_name
that server_name _; is treated specially for requests with no Host
header, however, on the latest dev version this is not so.

If a request on the IP or on a domain without a matching server_block
comes in then Nginx will either choose the server block with
default_server flag in listen or the first one defined.

Question is, is this is a bug or should we update the wiki to no longer
mention _?

Sincerely,
Martin Fjordvald

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,130108,130108#msg-130108




More information about the nginx mailing list