Aria2 Docker Nginx配置

#PROXY-START/
location  ~* \.(php|jsp|cgi|asp|aspx)$
{
    proxy_pass http://127.0.0.1:44561;
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header REMOTE-HOST $remote_addr;
}

location ^~ /jsonrpc {
    proxy_http_version 1.1;
    add_header Front-End-Https on;
    proxy_set_header Connection "";
    proxy_set_header Host $http_host;
    proxy_set_header X-NginX-Proxy true;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_pass http://127.0.0.1:6800/jsonrpc;
    proxy_pass_header X-Transmission-Session-Id;
}

#PROXY-END/

V2Ray Docker反代

location /xxxxxx
    {
        proxy_redirect off;
        proxy_pass http://127.0.0.1:44561;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_set_header Host $http_host;
        proxy_read_timeout 300s;
    }

Jupyter Lab 反代

location / 
{
    proxy_pass http://192.168.91.138:18882;
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header REMOTE-HOST $remote_addr;
    
    #缓存相关配置
    #proxy_cache cache_one;
    #proxy_cache_key $host$request_uri$is_args$args;
    #proxy_cache_valid 200 304 301 302 1h;
    
    #持久化连接相关 WebSocket 配置
    proxy_connect_timeout 30s;
    proxy_read_timeout 86400s;
    proxy_send_timeout 30s;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "upgrade";        
    expires 12h;
}
Last modification:May 17th, 2020 at 10:52 am
如果觉得我的文章对你有用,请随意赞赏