18045010223
7 天以前 afe371d39a054b2f2a9e5875b945584eec8a8141
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# 使用多个域名的模式
# 通过将多个域名都反向代理到音视频服务器的3333端口
# 为单个域名的6路并发,扩展到 n * 6路,每增加一个域名就可以多出6路并发
# 流媒体URL如:
#     http://v1.hentai.org.cn/video/013800138999-2
#     http://v2.hentai.org.cn/video/013800138999-2
 
server
{
    listen 80;
    server_name v1.hentai.org.cn v2.hentai.org.cn v3.hentai.org.cn v4.hentai.org.cn v5.hentai.org.cn v6.hentai.org.cn;
    location /
    {
        proxy_pass http://localhost:3333;
        chunked_transfer_encoding on;
        add_header 'Access-Control-Allow-Origin' '*';
        add_header 'Access-Control-Allow-Credentials' 'true';
    }
    access_log off;
}
 
# -------------------------------------------------- 华丽的分割线 --------------------------------------------------
 
# 使用多个端口的模式
# 每多一个端口配置,就可以多出6路并发
# 流媒体URL如:
#     http://192.168.0.2:1000/video/013800138999-2
#     http://192.168.0.2:1001/video/013800138999-2
#     http://192.168.0.2:1002/video/013800138999-2
 
server
{
    listen 1000;
    location /
    {
        proxy_pass http://localhost:3333;
        chunked_transfer_encoding on;
    }
    access_log off;
}
 
server
{
    listen 1001;
    location /
    {
        proxy_pass http://localhost:3333;
        chunked_transfer_encoding on;
    }
    access_log off;
}
 
server
{
    listen 1002;
    location /
    {
        proxy_pass http://localhost:3333;
        chunked_transfer_encoding on;
    }
    access_log off;
}