|
@@ -23,44 +23,54 @@ server |
|
@@ -23,44 +23,54 @@ server |
23
|
}
|
23
|
}
|
24
|
|
24
|
|
25
|
location = /reg.html {
|
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";
|
26
|
+ return 301 https://$server_name$request_uri;
|
|
|
27
|
+
|
|
|
28
|
+# proxy_redirect off;
|
|
|
29
|
+# proxy_pass http://yohobuy;
|
|
|
30
|
+# proxy_set_header Host $host;
|
|
|
31
|
+# proxy_set_header X-Real-IP $remote_addr;
|
|
|
32
|
+# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
33
|
+# proxy_set_header Accept-Encoding "gzip";
|
32
|
}
|
34
|
}
|
33
|
location = /signin.html {
|
35
|
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";
|
36
|
+ return 301 https://$server_name$request_uri;
|
|
|
37
|
+
|
|
|
38
|
+# proxy_redirect off;
|
|
|
39
|
+# proxy_pass http://yohobuy;
|
|
|
40
|
+# proxy_set_header Host $host;
|
|
|
41
|
+# proxy_set_header X-Real-IP $remote_addr;
|
|
|
42
|
+# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
43
|
+# proxy_set_header Accept-Encoding "gzip";
|
40
|
}
|
44
|
}
|
41
|
location = /login.html {
|
45
|
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";
|
46
|
+ return 301 https://$server_name$request_uri;
|
|
|
47
|
+
|
|
|
48
|
+# proxy_redirect off;
|
|
|
49
|
+# proxy_pass http://yohobuy;
|
|
|
50
|
+# proxy_set_header Host $host;
|
|
|
51
|
+# proxy_set_header X-Real-IP $remote_addr;
|
|
|
52
|
+# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
53
|
+# proxy_set_header Accept-Encoding "gzip";
|
48
|
}
|
54
|
}
|
49
|
location = /emailback.html {
|
55
|
location = /emailback.html {
|
50
|
- proxy_redirect off;
|
|
|
51
|
- proxy_pass http://yohobuy;
|
|
|
52
|
- proxy_set_header Host $host;
|
|
|
53
|
- proxy_set_header X-Real-IP $remote_addr;
|
|
|
54
|
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
55
|
- proxy_set_header Accept-Encoding "gzip";
|
56
|
+ return 301 https://$server_name$request_uri;
|
|
|
57
|
+
|
|
|
58
|
+# proxy_redirect off;
|
|
|
59
|
+# proxy_pass http://yohobuy;
|
|
|
60
|
+# proxy_set_header Host $host;
|
|
|
61
|
+# proxy_set_header X-Real-IP $remote_addr;
|
|
|
62
|
+# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
63
|
+# proxy_set_header Accept-Encoding "gzip";
|
56
|
}
|
64
|
}
|
57
|
location = /phoneback.html {
|
65
|
location = /phoneback.html {
|
58
|
- proxy_redirect off;
|
|
|
59
|
- proxy_pass http://yohobuy;
|
|
|
60
|
- proxy_set_header Host $host;
|
|
|
61
|
- proxy_set_header X-Real-IP $remote_addr;
|
|
|
62
|
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
63
|
- proxy_set_header Accept-Encoding "gzip";
|
66
|
+ return 301 https://$server_name$request_uri;
|
|
|
67
|
+
|
|
|
68
|
+# proxy_redirect off;
|
|
|
69
|
+# proxy_pass http://yohobuy;
|
|
|
70
|
+# proxy_set_header Host $host;
|
|
|
71
|
+# proxy_set_header X-Real-IP $remote_addr;
|
|
|
72
|
+# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
73
|
+# proxy_set_header Accept-Encoding "gzip";
|
64
|
}
|
74
|
}
|
65
|
location = /help/shareorder.html {
|
75
|
location = /help/shareorder.html {
|
66
|
root /Data/code/git/yohobuy/yohobuy/assets;
|
76
|
root /Data/code/git/yohobuy/yohobuy/assets;
|
|
@@ -70,28 +80,34 @@ server |
|
@@ -70,28 +80,34 @@ server |
70
|
expires 7d;
|
80
|
expires 7d;
|
71
|
}
|
81
|
}
|
72
|
location ^~ /passport/reg {
|
82
|
location ^~ /passport/reg {
|
73
|
- proxy_redirect off;
|
|
|
74
|
- proxy_pass http://yohobuy;
|
|
|
75
|
- proxy_set_header Host $host;
|
|
|
76
|
- proxy_set_header X-Real-IP $remote_addr;
|
|
|
77
|
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
78
|
- proxy_set_header Accept-Encoding "gzip";
|
83
|
+ return 301 https://$server_name$request_uri;
|
|
|
84
|
+
|
|
|
85
|
+# proxy_redirect off;
|
|
|
86
|
+# proxy_pass http://yohobuy;
|
|
|
87
|
+# proxy_set_header Host $host;
|
|
|
88
|
+# proxy_set_header X-Real-IP $remote_addr;
|
|
|
89
|
+# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
90
|
+# proxy_set_header Accept-Encoding "gzip";
|
79
|
}
|
91
|
}
|
80
|
location ^~ /passport/login {
|
92
|
location ^~ /passport/login {
|
81
|
- proxy_redirect off;
|
|
|
82
|
- proxy_pass http://yohobuy;
|
|
|
83
|
- proxy_set_header Host $host;
|
|
|
84
|
- proxy_set_header X-Real-IP $remote_addr;
|
|
|
85
|
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
86
|
- proxy_set_header Accept-Encoding "gzip";
|
93
|
+ return 301 https://$server_name$request_uri;
|
|
|
94
|
+
|
|
|
95
|
+# proxy_redirect off;
|
|
|
96
|
+# proxy_pass http://yohobuy;
|
|
|
97
|
+# proxy_set_header Host $host;
|
|
|
98
|
+# proxy_set_header X-Real-IP $remote_addr;
|
|
|
99
|
+# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
100
|
+# proxy_set_header Accept-Encoding "gzip";
|
87
|
}
|
101
|
}
|
88
|
location ^~ /passport/back {
|
102
|
location ^~ /passport/back {
|
89
|
- proxy_redirect off;
|
|
|
90
|
- proxy_pass http://yohobuy;
|
|
|
91
|
- proxy_set_header Host $host;
|
|
|
92
|
- proxy_set_header X-Real-IP $remote_addr;
|
|
|
93
|
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
94
|
- proxy_set_header Accept-Encoding "gzip";
|
103
|
+ return 301 https://$server_name$request_uri;
|
|
|
104
|
+
|
|
|
105
|
+# proxy_redirect off;
|
|
|
106
|
+# proxy_pass http://yohobuy;
|
|
|
107
|
+# proxy_set_header Host $host;
|
|
|
108
|
+# proxy_set_header X-Real-IP $remote_addr;
|
|
|
109
|
+# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
110
|
+# proxy_set_header Accept-Encoding "gzip";
|
95
|
}
|
111
|
}
|
96
|
|
112
|
|
97
|
location = / {
|
113
|
location = / {
|
|
@@ -364,4 +380,78 @@ server |
|
@@ -364,4 +380,78 @@ server |
364
|
|
380
|
|
365
|
}
|
381
|
}
|
366
|
|
382
|
|
|
|
383
|
+server
|
|
|
384
|
+{
|
|
|
385
|
+ listen 80;
|
|
|
386
|
+ server_name huodong.m.yohobuy.com;
|
|
|
387
|
+ root /Data/PE/yohobuy/yohobuy/huodong.m.yohobuy.com/public;
|
|
|
388
|
+ location / {
|
|
|
389
|
+ proxy_redirect off;
|
|
|
390
|
+ proxy_pass http://yohobuy;
|
|
|
391
|
+ proxy_set_header Host $host;
|
|
|
392
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
393
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
394
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
395
|
+ }
|
367
|
|
396
|
|
|
|
397
|
+ location ~* \.(ico|woff|svg|eot|ttf|otf)$ {
|
|
|
398
|
+ expires 30d;
|
|
|
399
|
+ }
|
|
|
400
|
+ location =/crossdomain.xml {
|
|
|
401
|
+ expires 30d;
|
|
|
402
|
+ }
|
|
|
403
|
+ location =/sitemap.xml {
|
|
|
404
|
+ expires 1d;
|
|
|
405
|
+ }
|
|
|
406
|
+ location =/robots.txt {
|
|
|
407
|
+ expires 1d;
|
|
|
408
|
+ }
|
|
|
409
|
+}
|
|
|
410
|
+
|
|
|
411
|
+server
|
|
|
412
|
+{
|
|
|
413
|
+ listen 443 ssl;
|
|
|
414
|
+ server_name login.m.yohobuy.com;
|
|
|
415
|
+ root /Data/PE/yohobuy/yohobuy/m.yohobuy.com/public;
|
|
|
416
|
+
|
|
|
417
|
+ ssl_certificate /home/hf/ssl/server.crt;
|
|
|
418
|
+ ssl_certificate_key /home/hf/ssl/server.key;
|
|
|
419
|
+ ssl_dhparam /home/hf/ssl/dhparams.pem;
|
|
|
420
|
+
|
|
|
421
|
+ ssl_prefer_server_ciphers on;
|
|
|
422
|
+ ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
|
|
|
423
|
+ ssl_ciphers "ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256:AES128-GCM-SHA256:AES256-GCM-SHA384:DES-CBC3-SHA";
|
|
|
424
|
+ ssl_session_tickets off;
|
|
|
425
|
+ ssl_session_cache shared:SSL:10m;
|
|
|
426
|
+
|
|
|
427
|
+# add_header Strict-Transport-Security "max-age=31536000";
|
|
|
428
|
+# add_header X-Frame-Options deny;
|
|
|
429
|
+# add_header X-Content-Type-Options nosniff;
|
|
|
430
|
+
|
|
|
431
|
+ location / {
|
|
|
432
|
+ proxy_redirect off;
|
|
|
433
|
+ proxy_pass http://yohobuy;
|
|
|
434
|
+ proxy_set_header Host $host;
|
|
|
435
|
+ proxy_set_header X-Real-IP $remote_addr;
|
|
|
436
|
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
437
|
+ proxy_set_header Accept-Encoding "gzip";
|
|
|
438
|
+ }
|
|
|
439
|
+
|
|
|
440
|
+ location ^~ /dist/ {
|
|
|
441
|
+ root /Data/PE/yohobuy/yohobuy/static;
|
|
|
442
|
+ expires 30d;
|
|
|
443
|
+ }
|
|
|
444
|
+
|
|
|
445
|
+ location ~* \.(ico|woff|svg|eot|ttf|otf)$ {
|
|
|
446
|
+ expires 30d;
|
|
|
447
|
+ }
|
|
|
448
|
+ location =/crossdomain.xml {
|
|
|
449
|
+ expires 30d;
|
|
|
450
|
+ }
|
|
|
451
|
+ location =/sitemap.xml {
|
|
|
452
|
+ expires 1d;
|
|
|
453
|
+ }
|
|
|
454
|
+ location =/robots.txt {
|
|
|
455
|
+ expires 1d;
|
|
|
456
|
+ }
|
|
|
457
|
+} |