pixman 和 pix-nginx 都跑起来了了 使用 ip 端口可以订阅 M3U 文件 就是无法播放
docker 用户自定义脚本
docker run -d --name=pixman -p 5051:5000 -e http_proxy=http://192.168.31.1:7890 -e https_proxy=http://192.168.31.1:7890 pixman/pixman
docker run -d --name=pixman-nginx -p 8008:8000 -p 9090:9000 -v /volume2/docker/pixman/nginx:/etc/nginx/conf.d --restart=always nginx
配置文件
1.docker-compose.yml
services:
pixman:
image: pixman/pixman:latest
restart: always
container_name: pixman
environment:
- http_proxy=http://192.168.31.1:7890
- https_proxy=http://192.168.31.1:7890
- MYTVSUPER_TOKEN=TOKEN
ports:
- 5051:5000
pixman-nginx:
image: nginx:latest
restart: always
container_name: pixman-nginx
ports:
- 8008:8000
- 9090:9000
volumes:
- ./nginx:/etc/nginx/conf.d
2.itv.conf
server {
# 需要映射 9000 端口
listen 9090 default_server;
location ~ ^/(?<cdn>ystenlive|bestlive|wasulive|fifalive|hnbblive)(?<path>.*) {
resolver 233.5.5.5; # 可以更改为其他 dns 服务或者你自己的路由器
set $target_url http://pixman.io.$cdn.dnsany.com$path$is_args$args;
set $cdn_host cache.ott.$cdn.itv.cmvideo.cn;
proxy_pass $target_url;
proxy_set_header Host $cdn_host;
}
}
3.tptv.conf
server {
listen 8001 default_server;
location / {
set $ua 'okhttp/3';
if ($arg_ua) {
set $ua $arg_ua;
}
proxy_pass http://tptv1.mobaibox.com;
proxy_set_header Host tptv1.mobaibox.com;
proxy_set_header User-Agent $ua;
proxy_connect_timeout 3;
}
}
server {
listen 8002 default_server;
location / {
set $ua 'okhttp/3';
if ($arg_ua) {
set $ua $arg_ua;
}
proxy_pass http://tptv2.mobaibox.com;
proxy_set_header Host tptv2.mobaibox.com;
proxy_set_header User-Agent $ua;
proxy_connect_timeout 3;
}
}
upstream cdn_server {
server 127.0.0.1:8001 weight=1 max_fails=1 fail_timeout=60s;
# tptv2.mobaibox.com 貌似被关闭,暂时注释掉
# server 127.0.0.1:8002 weight=1 max_fails=1 fail_timeout=60s;
}
server {
listen 8008 default_server;
location / {
proxy_next_upstream error timeout http_502 http_503 http_504;
proxy_pass http://cdn_server;
}
}
麻烦大佬看下哪里的问题。