-
Notifications
You must be signed in to change notification settings - Fork 550
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
[功能请求] 能否加入node组的概念 #648
Comments
如果能在现有的结构上简单的扩展就不建议增加新的结构。例如可以定义一种引用类型的节点来共享配置,并可以覆写部分字段 nodes:
- name: node-0
addr: 1.1.1.1:1080
connector:
type: socks5
dialer:
type: tcp
- name: node-1
ref: node-0
addr: 1.1.1.1:1080 node-1节点通过 |
这是一个很好的方案,期望能增加此功能 |
建议直接使用 YAML 高级操作: junk:
- &common-socks5
connector:
type: socks5
dialer:
type: tcp
- &common-auto
connector:
type: auto
dialer:
type: tcp
nodes:
- name: node-0
<<: *common-socks5
addr: 1.1.1.1:1080
- name: node-1
<<: *common-socks5
addr: 1.1.1.1:1081 顶层的 |
但是在使用API进行编辑时只能使用json格式编辑,就无法使用这个高级功能了,所以如果能够从底层加入特殊字段来支持是更通用的办法 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
目前没找到关于node组的配置,是否有计划增加支持?
举例来说,目前一个hop里面可以配置多个node节点,通过选择器来选择不同的节点使用。但是在配置多个node时,如果connector和dialer的配置都是一样的,需要重复编写N次。
引入nodeGroup概念后,可以对connector和dialer配置相同的node分到同一组,仅设置一次connector和dialer配置,各个不同node仅需配置不同的addr参数即可,配置文件形如:
The text was updated successfully, but these errors were encountered: