|
|
1
|
+
|
|
|
2
|
+server
|
|
|
3
|
+{
|
|
|
4
|
+ listen 80;
|
|
|
5
|
+ server_name m.yohobuy.com *.m.yohobuy.com;
|
|
|
6
|
+
|
|
|
7
|
+ #access_log /Data/logs/access.buy.test.yoho.cn.log combined;
|
|
|
8
|
+ error_log /Data/logs/nginx/error.m.yohobuy.com.log warn;
|
|
|
9
|
+
|
|
|
10
|
+ root /Data/code/git/yohobuy/yohobuy/m.yohobuy.com/public;
|
|
|
11
|
+
|
|
|
12
|
+ location ~* \.(ico|woff)$ {
|
|
|
13
|
+ expires 7d;
|
|
|
14
|
+ }
|
|
|
15
|
+
|
|
|
16
|
+ location = /crossdomain.xml {
|
|
|
17
|
+ expires 7d;
|
|
|
18
|
+ }
|
|
|
19
|
+
|
|
|
20
|
+ location = /appembed {
|
|
|
21
|
+ default_type application/json;
|
|
|
22
|
+ return 200 '{"code":200,"message":"appembed","data":{"open":"N","url":"http://m.yohobuy.com"}}';
|
|
|
23
|
+ }
|
|
|
24
|
+
|
|
|
25
|
+ location = /reg.html {
|
|
|
26
|
+ proxy_redirect off;
|
|
|
27
|
+ proxy_pass http://yohobuy;
|
|
|
28
|
+ proxy_set_header Host $host;
|
|
|
29
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
30
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
31
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
32
|
+ }
|
|
|
33
|
+ location = /signin.html {
|
|
|
34
|
+ proxy_redirect off;
|
|
|
35
|
+ proxy_pass http://yohobuy;
|
|
|
36
|
+ proxy_set_header Host $host;
|
|
|
37
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
38
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
39
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
40
|
+ }
|
|
|
41
|
+ location = /login.html {
|
|
|
42
|
+ proxy_redirect off;
|
|
|
43
|
+ proxy_pass http://yohobuy;
|
|
|
44
|
+ proxy_set_header Host $host;
|
|
|
45
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
46
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
47
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
48
|
+ }
|
|
|
49
|
+ location = /emailback.html {
|
|
|
50
|
+ root /Data/code/git/yohobuy/yohobuy/assets;
|
|
|
51
|
+ expires 7d;
|
|
|
52
|
+ }
|
|
|
53
|
+ location = /phoneback.html {
|
|
|
54
|
+ root /Data/code/git/yohobuy/yohobuy/assets;
|
|
|
55
|
+ expires 7d;
|
|
|
56
|
+ }
|
|
|
57
|
+ location = /error.html {
|
|
|
58
|
+ root /Data/code/git/yohobuy/yohobuy/assets;
|
|
|
59
|
+ expires 7d;
|
|
|
60
|
+ }
|
|
|
61
|
+ location ^~ /passport {
|
|
|
62
|
+ proxy_redirect off;
|
|
|
63
|
+ proxy_pass http://yohobuy;
|
|
|
64
|
+ proxy_set_header Host $host;
|
|
|
65
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
66
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
67
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
68
|
+ }
|
|
|
69
|
+
|
|
|
70
|
+ location = / {
|
|
|
71
|
+ proxy_redirect off;
|
|
|
72
|
+ proxy_pass http://yohobuy;
|
|
|
73
|
+ proxy_set_header Host $host;
|
|
|
74
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
75
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
76
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
77
|
+ }
|
|
|
78
|
+
|
|
|
79
|
+ location = /boys {
|
|
|
80
|
+ proxy_redirect off;
|
|
|
81
|
+ proxy_pass http://yohobuy;
|
|
|
82
|
+ proxy_set_header Host $host;
|
|
|
83
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
84
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
85
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
86
|
+ }
|
|
|
87
|
+ location = /girls {
|
|
|
88
|
+ proxy_redirect off;
|
|
|
89
|
+ proxy_pass http://yohobuy;
|
|
|
90
|
+ proxy_set_header Host $host;
|
|
|
91
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
92
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
93
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
94
|
+ }
|
|
|
95
|
+ location = /kids {
|
|
|
96
|
+ proxy_redirect off;
|
|
|
97
|
+ proxy_pass http://yohobuy;
|
|
|
98
|
+ proxy_set_header Host $host;
|
|
|
99
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
100
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
101
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
102
|
+ }
|
|
|
103
|
+ location = /lifestyle {
|
|
|
104
|
+ proxy_redirect off;
|
|
|
105
|
+ proxy_pass http://yohobuy;
|
|
|
106
|
+ proxy_set_header Host $host;
|
|
|
107
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
108
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
109
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
110
|
+ }
|
|
|
111
|
+ location = /girl {
|
|
|
112
|
+ proxy_redirect off;
|
|
|
113
|
+ proxy_pass http://yohobuy;
|
|
|
114
|
+ proxy_set_header Host $host;
|
|
|
115
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
116
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
117
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
118
|
+ }
|
|
|
119
|
+
|
|
|
120
|
+ location = /boys/bottomBanner {
|
|
|
121
|
+ proxy_redirect off;
|
|
|
122
|
+ proxy_pass http://yohobuy;
|
|
|
123
|
+ proxy_set_header Host $host;
|
|
|
124
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
125
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
126
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
127
|
+ }
|
|
|
128
|
+ location = /girls/bottomBanner {
|
|
|
129
|
+ proxy_redirect off;
|
|
|
130
|
+ proxy_pass http://yohobuy;
|
|
|
131
|
+ proxy_set_header Host $host;
|
|
|
132
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
133
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
134
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
135
|
+ }
|
|
|
136
|
+
|
|
|
137
|
+ location = /cate {
|
|
|
138
|
+ proxy_redirect off;
|
|
|
139
|
+ proxy_pass http://yohobuy;
|
|
|
140
|
+ proxy_set_header Host $host;
|
|
|
141
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
142
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
143
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
144
|
+ }
|
|
|
145
|
+ location = /brands {
|
|
|
146
|
+ proxy_redirect off;
|
|
|
147
|
+ proxy_pass http://yohobuy;
|
|
|
148
|
+ proxy_set_header Host $host;
|
|
|
149
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
150
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
151
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
152
|
+ }
|
|
|
153
|
+ location = /sale {
|
|
|
154
|
+ proxy_redirect off;
|
|
|
155
|
+ proxy_pass http://yohobuy;
|
|
|
156
|
+ proxy_set_header Host $host;
|
|
|
157
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
158
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
159
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
160
|
+ }
|
|
|
161
|
+ location = /brands/search {
|
|
|
162
|
+ proxy_redirect off;
|
|
|
163
|
+ proxy_pass http://yohobuy;
|
|
|
164
|
+ proxy_set_header Host $host;
|
|
|
165
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
166
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
167
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
168
|
+ }
|
|
|
169
|
+ location = /product/new {
|
|
|
170
|
+ proxy_redirect off;
|
|
|
171
|
+ proxy_pass http://yohobuy;
|
|
|
172
|
+ proxy_set_header Host $host;
|
|
|
173
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
174
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
175
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
176
|
+ }
|
|
|
177
|
+ location = /hotrank {
|
|
|
178
|
+ proxy_redirect off;
|
|
|
179
|
+ proxy_pass http://yohobuy;
|
|
|
180
|
+ proxy_set_header Host $host;
|
|
|
181
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
182
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
183
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
184
|
+ }
|
|
|
185
|
+
|
|
|
186
|
+ location ^~ /product/newsale/ {
|
|
|
187
|
+ proxy_redirect off;
|
|
|
188
|
+ proxy_pass http://yohobuy;
|
|
|
189
|
+ proxy_set_header Host $host;
|
|
|
190
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
191
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
192
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
193
|
+ }
|
|
|
194
|
+ location ^~ /product/opt/ {
|
|
|
195
|
+ proxy_redirect off;
|
|
|
196
|
+ proxy_pass http://yohobuy;
|
|
|
197
|
+ proxy_set_header Host $host;
|
|
|
198
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
199
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
200
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
201
|
+ }
|
|
|
202
|
+ location ^~ /product/recom/ {
|
|
|
203
|
+ proxy_redirect off;
|
|
|
204
|
+ proxy_pass http://yohobuy;
|
|
|
205
|
+ proxy_set_header Host $host;
|
|
|
206
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
207
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
208
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
209
|
+ }
|
|
|
210
|
+ location ^~ /product/pro_ {
|
|
|
211
|
+ proxy_redirect off;
|
|
|
212
|
+ proxy_pass http://yohobuy;
|
|
|
213
|
+ proxy_set_header Host $host;
|
|
|
214
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
215
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
216
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
217
|
+ }
|
|
|
218
|
+ location ^~ /product/intro_ {
|
|
|
219
|
+ proxy_redirect off;
|
|
|
220
|
+ proxy_pass http://yohobuy;
|
|
|
221
|
+ proxy_set_header Host $host;
|
|
|
222
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
223
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
224
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
225
|
+ }
|
|
|
226
|
+ location ^~ /product/detail/ {
|
|
|
227
|
+ proxy_redirect off;
|
|
|
228
|
+ proxy_pass http://yohobuy;
|
|
|
229
|
+ proxy_set_header Host $host;
|
|
|
230
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
231
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
232
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
233
|
+ }
|
|
|
234
|
+
|
|
|
235
|
+ location ^~ /guang/ {
|
|
|
236
|
+ proxy_redirect off;
|
|
|
237
|
+ proxy_pass http://yohobuy;
|
|
|
238
|
+ proxy_set_header Host $host;
|
|
|
239
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
240
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
241
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
242
|
+ }
|
|
|
243
|
+ location ^~ /tags/index {
|
|
|
244
|
+ proxy_redirect off;
|
|
|
245
|
+ proxy_pass http://yohobuy;
|
|
|
246
|
+ proxy_set_header Host $host;
|
|
|
247
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
248
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
249
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
250
|
+ }
|
|
|
251
|
+ location ^~ /author/index {
|
|
|
252
|
+ proxy_redirect off;
|
|
|
253
|
+ proxy_pass http://yohobuy;
|
|
|
254
|
+ proxy_set_header Host $host;
|
|
|
255
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
256
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
257
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
258
|
+ }
|
|
|
259
|
+ location ^~ /info/index {
|
|
|
260
|
+ proxy_redirect off;
|
|
|
261
|
+ proxy_pass http://yohobuy;
|
|
|
262
|
+ proxy_set_header Host $host;
|
|
|
263
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
264
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
265
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
266
|
+ }
|
|
|
267
|
+ location ^~ /plustar {
|
|
|
268
|
+ proxy_redirect off;
|
|
|
269
|
+ proxy_pass http://yohobuy;
|
|
|
270
|
+ proxy_set_header Host $host;
|
|
|
271
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
272
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
273
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
274
|
+ }
|
|
|
275
|
+
|
|
|
276
|
+ location ^~ /search {
|
|
|
277
|
+ proxy_redirect off;
|
|
|
278
|
+ proxy_pass http://yohobuy;
|
|
|
279
|
+ proxy_set_header Host $host;
|
|
|
280
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
281
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
282
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
283
|
+ }
|
|
|
284
|
+
|
|
|
285
|
+ location ^~ /index/search {
|
|
|
286
|
+ proxy_redirect off;
|
|
|
287
|
+ proxy_pass http://yohobuy;
|
|
|
288
|
+ proxy_set_header Host $host;
|
|
|
289
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
290
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
291
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
292
|
+ }
|
|
|
293
|
+
|
|
|
294
|
+ location ^~ /home {
|
|
|
295
|
+ proxy_redirect off;
|
|
|
296
|
+ proxy_pass http://yohobuy;
|
|
|
297
|
+ proxy_set_header Host $host;
|
|
|
298
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
299
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
300
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
301
|
+ }
|
|
|
302
|
+
|
|
|
303
|
+ location ^~ /home/message {
|
|
|
304
|
+ proxy_redirect off;
|
|
|
305
|
+ proxy_pass http://61.155.222.163;
|
|
|
306
|
+ proxy_set_header Host m.yohobuy.com;
|
|
|
307
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
308
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
309
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
310
|
+ }
|
|
|
311
|
+
|
|
|
312
|
+ location = /home/orders/detail {
|
|
|
313
|
+ proxy_redirect off;
|
|
|
314
|
+ proxy_pass http://61.155.222.163;
|
|
|
315
|
+ proxy_set_header Host m.yohobuy.com;
|
|
|
316
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
317
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
318
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
319
|
+ }
|
|
|
320
|
+ location = /home/orders/cancel {
|
|
|
321
|
+ proxy_redirect off;
|
|
|
322
|
+ proxy_pass http://61.155.222.163;
|
|
|
323
|
+ proxy_set_header Host m.yohobuy.com;
|
|
|
324
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
325
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
326
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
327
|
+ }
|
|
|
328
|
+
|
|
|
329
|
+ location / {
|
|
|
330
|
+ proxy_redirect off;
|
|
|
331
|
+ proxy_pass http://61.155.222.163;
|
|
|
332
|
+ proxy_set_header Host m.yohobuy.com;
|
|
|
333
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
334
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
335
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
336
|
+ }
|
|
|
337
|
+
|
|
|
338
|
+}
|
|
|
339
|
+
|
|
|
340
|
+server
|
|
|
341
|
+{
|
|
|
342
|
+ listen 80;
|
|
|
343
|
+ server_name cdn.yoho.cn;
|
|
|
344
|
+
|
|
|
345
|
+ #access_log /Data/logs/nginx/access.static.m.yohobuy.com.log combined;
|
|
|
346
|
+ #error_log /Data/logs/nginx/error.static.m.yohobuy.com.log warn;
|
|
|
347
|
+
|
|
|
348
|
+ root /Data/code/git/yohobuy/static/dist;
|
|
|
349
|
+
|
|
|
350
|
+ location / {
|
|
|
351
|
+ log_not_found off;
|
|
|
352
|
+ access_log off;
|
|
|
353
|
+ expires 30d;
|
|
|
354
|
+ }
|
|
|
355
|
+
|
|
|
356
|
+ location ~* \.(svg|eot|ttf|woff|otf)$ {
|
|
|
357
|
+ add_header Access-Control-Allow-Origin *;
|
|
|
358
|
+ expires 30d;
|
|
|
359
|
+ }
|
|
|
360
|
+
|
|
|
361
|
+}
|
|
|
362
|
+ |