Proxy name jump

server {
          listen  80;
          server_name *.baidu.com;         
          if ($host ~ (.).baidu.com) {
          set $host_without_www $1; 
          rewrite ^(.)$ http://$host_without_www.hao123.com permanent;
       }

发表评论