Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

非CN服务器,部署本项目,仍然存在歌曲无法提示需要会员的情况。 #1496

Open
PoetryU opened this issue Oct 9, 2024 · 3 comments
Labels
enhancement New feature or request

Comments

@PoetryU
Copy link

PoetryU commented Oct 9, 2024

需求描述

在非CN服务器通过docker部署了本项目

docker run  -d -p 12345:8080  -m 300M --memory-swap -1 -e ENABLE_LOCAL_VIP=true -e NO_CACHE=true -e ENABLE_FLAC=true -e NODE_ENV=production --restart=always --log-opt max-size=10m --name=win_music pan93412/unblock-netease-music-enhanced:latest -e https://music.163.com

会员歌曲仍然无法解决。LOCAL_VIP 是可以的。
image


请问国外机是不是无解?

预期行为

No response

网易云音乐版本号

No response

操作系统

all

其他信息

No response

@PoetryU PoetryU added the enhancement New feature or request label Oct 9, 2024
@luoxingran
Copy link

需要自己修改请求头用X-Forwarded-For IP伪装为国内IP解决海外地区版权受限问题

@PoetryU
Copy link
Author

PoetryU commented Oct 11, 2024

大佬能够进一步指点一下吗?如何修改呢?用nginx?

server {
        listen 12345;
        server_name  music.example.com;
        access_log /www/wwwroot/music/music.log;
        error_log /www/wwwroot/music/music.error;
        location / {
            proxy_set_header Host $host;
            proxy_set_header X-Forwarded-For {fake-ip} ;
            proxy_pass http://127.0.0.1:5163;
        }

    }

其中5163端口为本项目服务,通过nginx转发到12345端口

可是我通过12345还是不行

@luoxingran
Copy link

修改项目源码,在api的请求头上面加ip伪装,比如kuwo request('GET', url, { 'user-agent': 'okhttp/3.10.0' }) 改成 request('GET', url, { 'user-agent': 'okhttp/3.10.0','X-Forwarded-For':'ip' })

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants