nginx config virtual hosts
Igor Sysoev
is at rambler-co.ru
Sat Dec 8 10:19:47 MSK 2007
On Fri, Dec 07, 2007 at 06:53:03PM -0800, rkmr.em at gmail.com wrote:
> I have this config and, www.domain2.com goes to domain1.com
> What do I set in server_name so that all sub-domain requests go to that
> server?
>
> xxx.domain2.com-> domain2
> thanks
>
>
> server {
> listen 80;
> server_name domain1.com;
>
>
> server {
> listen 80;
> server_name domain2.com;
If you do not need redirect, then:
server_name domain2.com *.domain2.com;
or (better):
server_name .domain2.com;
--
Igor Sysoev
http://sysoev.ru/en/
More information about the nginx
mailing list