-
Notifications
You must be signed in to change notification settings - Fork 274
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
如果我一个服务器的两个端口分别转发到不同服务器的不同端口怎么设置 #41
Comments
命令行只支持一條轉發規則,你可以開兩個進程; 也可以從配置文件啓動,配置文件是支持多條轉發規則的 #10 |
配置文件我也是研究半天,不是很明白 listening_ports 443 是固定对应1.1.1.1的443 还是说随机的也就是说会转发到1.1.1.1的1433上!因为中文介绍里的那段说明,不是很懂 |
Realm的轉發規則都是固定的,沒有負載均衡。每條轉發規則的 |
多谢。 |
我覺得還是從源碼的角度來解讀一下比較好。 首先規則數量取決於監聽的端口數量, 比如 每條規則的 舉個栗子,在前面的示例裏面多加10001端口: {
"listening_addresses": ["0.0.0.0"],
"listening_ports": ["443","1443", "10000-20000"],
"remote_addresses": ["1.1.1.1","2.2.2.2"],
"remote_ports": ["443","1443"]
} 除去前面說的兩條規則以外,新增的10001條規則的 監聽地址都是 |
其實我個人覺得Realm的配置文件格式不夠清晰,我更傾向於這種: [
{ "local": "0.0.0.0:443", "remote": "1.1.1.1:443" },
{ "local": "0.0.0.0:1443", "remote": "2.2.2.2:1443" }
] |
Couldn't agree more. |
懂了就是说没有对应的端口和IP都是默认第一个 |
Inspired by issue zhboner#41. PS:`-c` supports two kinds of config file import.
如果我一个服务器的两个端口分别转发到不同服务器的不同端口怎么设置
是用两条命令么?
The text was updated successfully, but these errors were encountered: