-
Notifications
You must be signed in to change notification settings - Fork 312
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
fix: fix the invalid IP address in src/server/test/config.ini #491
Conversation
src/server/test/config.ini
Outdated
@@ -503,5 +503,5 @@ onebox = 1 | |||
onebox2 = 2 | |||
|
|||
[pegasus.clusters] | |||
onebox = @LOCAL_IP@:34701,@LOCAL_IP@:34702,@LOCAL_IP@:34703 | |||
onebox2 = @LOCAL_IP@:34701,@LOCAL_IP@:34702,@LOCAL_IP@:34703 | |||
onebox = 0.0.0.0:34701,0.0.0.0:34702,0.0.0.0:34703 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
先查为什么travis上LOCAL_IP不会被替换
src/server/test/config.ini
Outdated
@@ -503,5 +503,5 @@ onebox = 1 | |||
onebox2 = 2 | |||
|
|||
[pegasus.clusters] | |||
onebox = @LOCAL_IP@:34701,@LOCAL_IP@:34702,@LOCAL_IP@:34703 | |||
onebox2 = @LOCAL_IP@:34701,@LOCAL_IP@:34702,@LOCAL_IP@:34703 | |||
onebox = 0.0.0.0:34701,0.0.0.0:34702,0.0.0.0:34703 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里用0.0.0.0的话,后面运行时会替换成本地ip地址吗?
src/server/test/run.sh
Outdated
@@ -1,13 +1,57 @@ | |||
#!/usr/bin/env bash |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
为什么删除#!
src/server/test/run.sh
Outdated
fi | ||
} | ||
|
||
LOCAL_IP=`get_local_ip` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
没必要复制一遍get_local_ip
你可以给这个脚本提供一个选项,提供LOCAL_IP变量
或者更简单的,把LOCAL_IP替换放在根目录run.sh run_test()里,这个run.sh就检测下config.ini有没有被替换就行了。如果有人单独执行这个脚本,可以更早发现config.ini的问题
Ref XiaoMi/rdsn#413