Ticket #289: nginx_best.conf

File nginx_best.conf, 986 bytes (added by zhangzhuojian, 12 years ago)

聚超值应用nginx配置

Line 
1http {
2    #最数码论坛服务
3    upstream WEB_APP {
4        server piebbs.pconline.com.cn:80;
5    }
6        #聚超倌应甚监听服务
7    server {
8        listen       80;
9                server_name  best.pconline.com.cn;
10
11        location ~ ^/bbs/$ {
12            rewrite /bbs/       /forum-best.html;  break;
13            proxy_pass          http://WEB_APP;
14            proxy_redirect      off;
15            proxy_set_header    Host             $host;
16            proxy_set_header    X-Real-IP        $remote_addr;
17            proxy_set_header    X-Forwarded-For  $proxy_add_x_forwarded_for;
18        }
19               
20                location ~ ^/bbs/(.*) {
21                        rewrite /bbs/(.*)   /$1;  break;
22            proxy_pass          http://WEB_APP;
23            proxy_redirect      off;
24            proxy_set_header    Host             $host;
25            proxy_set_header    X-Real-IP        $remote_addr;
26            proxy_set_header    X-Forwarded-For  $proxy_add_x_forwarded_for;
27                }
28                               
29    }  # end of server
30       
31}  # end of http