There is ambiguity in --host 0.0.0.0 from playground
Open
Nobody has claimed this yet.
component/playground
type/bug
- Dominant language
- Go
- Stars
- 466
- Forks
- 338
- Avg merge
- 3d 7h
- Merged PRs (30d)
- 8
Description
Bug Report
Please answer these questions before submitting your issue. Thanks!
- What did you do?
tiup playground --host 0.0.0.0 --monitor
- What did you expect to see?
tiup chose an ip in host,like 10.0.2.4. when i connect 127.0.0.1:4000 will be rejected. it is not expected. only can use 10.0.2.4:4000
CLUSTER START SUCCESSFULLY, Enjoy it ^-^
To connect TiDB: mysql --host 10.0.2.4 --port 4000 -u root -p (no password) --comments
To view the dashboard: http://10.0.2.4:2379/dashboard
PD client endpoints: [10.0.2.4:2379]
To view the Prometheus: http://10.0.2.4:9090
To view the Grafana: http://10.0.2.4:3000
- What did you see instead?
when a server is told to listen on 0.0. 0.0 that means "listen on every available network interface"。
in stdout,print a local ip.
- What version of TiUP are you using (
tiup --version)?
1.5.3 tiup
Go Version: go1.16.5
Git Ref: v1.5.3
GitHash: 222bd4d460eaa3fb6feec6ddeb8612fe0870ffd3
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the tiup playground --host 0.0.0.0 --monitor entry point and reproduce the displayed endpoints. Trace how the host address is selected for startup output. Done means the output clearly reflects the usable local connection address when binding to all interfaces, with behavior verified against the reported command.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli, networking
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100