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

[问题] docker启动时配置的PROXY_URL地址只能填写ip,不能填写域名 #1073

Closed
2 tasks done
cddc opened this issue Apr 25, 2023 · 2 comments
Closed
2 tasks done

Comments

@cddc
Copy link

cddc commented Apr 25, 2023

反馈须知

请在下方中括号内输入 x 来表示你已经知晓相关内容。

  • 我确认已经在 常见问题 中搜索了此次反馈的问题,没有找到解答;
  • 我确认已经在 Issues 列表(包括已经 Close 的)中搜索了此次反馈的问题,没有找到解答。

描述问题
采用docker部署的方式,启动docker时配置的PROXY_URL只能填写ip,不能填写域名。
如果填写域名,则会在docker logs里有报错信息:

xray_1  | [proxychains] config file found: /etc/proxychains.conf
xray_1  | [proxychains] preloading /usr/lib/libproxychains4.so
xray_1  | proxy XXXX.YYY.ZZZ has invalid value or is not numeric
xray_1  | non-numeric ips are only allowed under the following circumstances:
xray_1  | chaintype == strict (true), proxy is not first in list (false), proxy_dns active (thread)

从log报错中看出,大概应该是没有配置针对代理域名的dns解析导致的,但是我不知道应该怎么在这个docker理配置proxy_dns

如何复现
以下是docker-compose.yml

version: '3'
services:
  xray:
    image: yidadaa/chatgpt-next-web:v1.9.9
    ports:
      - "3000:3000"
    environment:
      OPENAI_API_KEY: .....
      CODE: ....
      PROXY_URL: http://XXX.YYY.ZZZ:1000
    hostname: chatgpt-next-web

截图
以下是docker logs的报错信息

xray_1  | strict_chain
xray_1  | proxy_dns
xray_1  | remote_dns_subnet 224
xray_1  | tcp_read_time_out 15000
xray_1  | tcp_connect_time_out 8000
xray_1  | [ProxyList]
xray_1  | http XXX.YYY.ZZZ 1000
xray_1  | [proxychains] config file found: /etc/proxychains.conf
xray_1  | [proxychains] preloading /usr/lib/libproxychains4.so
xray_1  | proxy XXX.YYY.ZZZ has invalid value or is not numeric
xray_1  | non-numeric ips are only allowed under the following circumstances:
xray_1  | chaintype == strict (true), proxy is not first in list (false), proxy_dns active (thread)
xray_1  | 

一些必要的信息

  • 将XXX.YYY.ZZZ域名,换成解析好的ip,则docker可以正常启动,服务运行正常。
@cddc
Copy link
Author

cddc commented Apr 25, 2023

另外代理配置上,不支持sock5h协议。
即,如果写socks5://127.0.0.1:12345是可以的,但是写sock5h://127.0.0.1:12345是不行的。
不知道是不是其依赖的proxychains模块本身有点问题

@Yidadaa
Copy link
Collaborator

Yidadaa commented Apr 25, 2023

参考这个解决:#1052

@Yidadaa Yidadaa closed this as completed Apr 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants