Authored by 梁志锋

备份nginx代码

@@ -194,7 +194,7 @@ @@ -194,7 +194,7 @@
194 } 194 }
195 195
196 location =/product/new/index { 196 location =/product/new/index {
197 - return 301 https://m.yohobuy.com/product/new; 197 + return 301 http://m.yohobuy.com/product/new;
198 } 198 }
199 199
200 200
@@ -208,22 +208,22 @@ @@ -208,22 +208,22 @@
208 } 208 }
209 209
210 location =/help.html { 210 location =/help.html {
211 - return 301 https://m.yohobuy.com/home/help; 211 + return 301 http://m.yohobuy.com/home/help;
212 } 212 }
213 213
214 location ^~ /trends_detail_ { 214 location ^~ /trends_detail_ {
215 - return 301 https://guang.m.yohobuy.com; 215 + return 301 http://guang.m.yohobuy.com;
216 } 216 }
217 217
218 - location =/about {  
219 - return 301 https://$host$request_uri;  
220 - } 218 + #location =/about {
  219 + # return 301 https://$host$request_uri;
  220 + # }
221 221
222 - location =/brand/index/about{  
223 - return 301 https://$host$request_uri;  
224 - } 222 + #location =/brand/index/about{
  223 + # return 301 https://$host$request_uri;
  224 + # }
225 225
226 # product detail page 301 redirect to item use https 226 # product detail page 301 redirect to item use https
227 location ^~ /product/pro_ { 227 location ^~ /product/pro_ {
228 - return 301 https://item.m.yohobuy.com$request_uri; 228 + return 301 http://item.m.yohobuy.com$request_uri;
229 } 229 }
@@ -63,8 +63,6 @@ server @@ -63,8 +63,6 @@ server
63 include vhosts/location/yohobuywap_idc.conf; 63 include vhosts/location/yohobuywap_idc.conf;
64 # app 64 # app
65 include vhosts/location/yohobuywap_app.conf; 65 include vhosts/location/yohobuywap_app.conf;
66 - # php  
67 - include vhosts/location/yohobuywap_php.conf;  
68 # node 66 # node
69 include vhosts/location/yohobuywap_node.conf; 67 include vhosts/location/yohobuywap_node.conf;
70 # static file 68 # static file
  1 +server
  2 +{
  3 + listen 80;
  4 + server_name m.yohobuy.com;
  5 +
  6 + #ssl_certificate /Data/local/nginx-1.8.0/conf/ssl/yohobuy.pem;
  7 + #ssl_certificate_key /Data/local/nginx-1.8.0/conf/ssl/yohobuy.key;
  8 +
  9 + root /Data/PE/yohobuy_H5/yohobuy/m.yohobuy.com/public;
  10 +
  11 + access_log /Data/logs/nginx/access_wap.yohobuy.com.log fenxi;
  12 + error_log /Data/logs/error_wap.yohobuy.com.log warn;
  13 +
  14 + # https key
  15 + #include vhosts/location/yohobuywap_httpskey.conf;
  16 + # old idc
  17 + include vhosts/location/yohobuywap_idc.conf;
  18 + # app
  19 + include vhosts/location/yohobuywap_app.conf;
  20 + # node
  21 + include vhosts/location/yohobuywap_node.conf;
  22 + # static file
  23 + include vhosts/location/yohobuywap_static.conf;
  24 +
  25 + #for wechat pay
  26 + location ^~ /home/orders/pay {
  27 + proxy_redirect off;
  28 + proxy_pass http://yohobuy;
  29 + proxy_set_header Host $host;
  30 + proxy_set_header X-Real-IP $remote_addr;
  31 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  32 + proxy_set_header Accept-Encoding "gzip";
  33 + }
  34 +
  35 + location ^~ /shopping/pay/wechatwapapi {
  36 + proxy_redirect off;
  37 + proxy_pass http://yohobuy;
  38 + proxy_set_header Host $host;
  39 + proxy_set_header X-Real-IP $remote_addr;
  40 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  41 + proxy_set_header Accept-Encoding "gzip";
  42 + }
  43 +
  44 + location =/shopping/pay/aliwapreturn {
  45 + proxy_redirect off;
  46 + proxy_pass http://yohobuy_idc;
  47 + proxy_set_header Host $host;
  48 + proxy_set_header X-Real-IP $remote_addr;
  49 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  50 + proxy_set_header Accept-Encoding "gzip";
  51 + }
  52 +
  53 + location / {
  54 + proxy_redirect off;
  55 + proxy_pass http://yohobuy;
  56 + proxy_set_header Host $host;
  57 + proxy_set_header X-Real-IP $remote_addr;
  58 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  59 + proxy_set_header Accept-Encoding "gzip";
  60 + }
  61 +
  62 +}
  63 +
  64 +server
  65 +{
  66 + listen 80;
  67 + server_name *.m.yohobuy.com;
  68 +
  69 + #ssl_certificate /Data/local/nginx-1.8.0/conf/ssl/m.yohobuy.pem;
  70 + #ssl_certificate_key /Data/local/nginx-1.8.0/conf/ssl/m.yohobuy.key;
  71 +
  72 + # https key
  73 + #include vhosts/location/yohobuywap_httpskey.conf;
  74 +
  75 +
  76 + access_log /Data/logs/nginx/access_wap.yohobuy.com.log fenxi;
  77 + error_log /Data/logs/error_wap.yohobuy.com.log warn;
  78 +
  79 + root /Data/PE/yohobuy_H5/yohobuy/m.yohobuy.com/public;
  80 +
  81 + # static file
  82 + include vhosts/location/yohobuywap_static.conf;
  83 +
  84 + # idc old proxy. while login to write memcache and cookie (if need?)
  85 + location ^~ /Passport/session {
  86 + access_log /Data/logs/access.m.yohobuy.com.log fenxi;
  87 + proxy_redirect off;
  88 + proxy_pass http://yohobuy_idc;
  89 + proxy_set_header Host mapi.yohobuy.com;
  90 + proxy_set_header X-Real-IP $remote_addr;
  91 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  92 + proxy_set_header Accept-Encoding "gzip";
  93 + }
  94 +
  95 + # guang rss
  96 + location ^~ /rss {
  97 + proxy_redirect off;
  98 + proxy_pass http://yohobuy;
  99 + proxy_set_header Host $host;
  100 + proxy_set_header X-Real-IP $remote_addr;
  101 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  102 + proxy_set_header Accept-Encoding "gzip";
  103 + }
  104 +
  105 + location / {
  106 + proxy_redirect off;
  107 + proxy_pass http://yohobuy;
  108 + proxy_set_header Host $host;
  109 + proxy_set_header X-Real-IP $remote_addr;
  110 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  111 + proxy_set_header Accept-Encoding "gzip";
  112 + }
  113 +}
  114 +
  115 +server
  116 +{
  117 + listen 80;
  118 + server_name cuxiao.m.yohobuy.com;
  119 +
  120 + access_log /Data/logs/nginx/access_wap.yohobuy.com.log fenxi;
  121 + error_log /Data/logs/error_wap.yohobuy.com.log warn;
  122 +
  123 + location / {
  124 + proxy_redirect off;
  125 + proxy_pass http://yohobuy_idc;
  126 + proxy_set_header Host cuxiao.m.yohobuy.com;
  127 + proxy_set_header X-Real-IP $remote_addr;
  128 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  129 + proxy_set_header Accept-Encoding "gzip";
  130 + }
  131 +}
  132 +
  133 + server
  134 +{
  135 + listen 80;
  136 + server_name analytics.m.yohobuy.com;
  137 +
  138 + #ssl_certificate /Data/local/nginx-1.8.0/conf/ssl/m.yohobuy.pem;
  139 + #ssl_certificate_key /Data/local/nginx-1.8.0/conf/ssl/m.yohobuy.key;
  140 +
  141 + # https key
  142 + #include vhosts/location/yohobuywap_httpskey.conf;
  143 +
  144 + location / {
  145 + proxy_redirect off;
  146 + proxy_pass http://yohobuy_analytics;
  147 + proxy_set_header Host $host;
  148 + proxy_set_header X-Real-IP $remote_addr;
  149 + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  150 + proxy_set_header Accept-Encoding "gzip";
  151 + }
  152 +
  153 +}
  154 +
  155 +server
  156 +{
  157 + listen 443;
  158 + server_name m.yohobuy.com;
  159 +
  160 + ssl_certificate /Data/local/nginx-1.8.0/conf/ssl/yohobuy.pem;
  161 + ssl_certificate_key /Data/local/nginx-1.8.0/conf/ssl/yohobuy.key;
  162 +
  163 + # https key
  164 + include vhosts/location/yohobuywap_httpskey.conf;
  165 +
  166 + location / {
  167 + return 301 http://$host$request_uri;
  168 + }
  169 +}
  170 +
  171 +server
  172 +{
  173 + listen 443;
  174 + server_name *.m.yohobuy.com;
  175 +
  176 + ssl_certificate /Data/local/nginx-1.8.0/conf/ssl/m.yohobuy.pem;
  177 + ssl_certificate_key /Data/local/nginx-1.8.0/conf/ssl/m.yohobuy.key;
  178 +
  179 + # https key
  180 + include vhosts/location/yohobuywap_httpskey.conf;
  181 +
  182 + location / {
  183 + return 301 http://$host$request_uri;
  184 + }
  185 +}