-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
cli: add a flag to allow listening on all interfaces #6862
Conversation
See also #5816, which is a request for a way to bind to multiple specific interfaces (but not all of them). I think it may be better to go ahead and implement a list of secondary addresses to bind instead a special case to bind to everything. |
FYI it's not so simple (golang/go#9334), so the multiple |
@tamird Can't you create a new listener for each address you want to listen on? You could probably wrap that up in a |
what does this give us over the use of |
@mberhault You can specify exactly which interfaces you listen on. |
sorry, I meant what does this current PR give us that |
right, but --host currently controls the advertised address as well as the listening address |
sure, but that has nothing at all to do with what we listen on. I would prefer to see |
Updated, PTAL. |
Related to cockroachdb#1008, extending cockroachdb#9503. Also see cockroachdb#6862. The flag enables any given node to advertise it's listening port. We have a similar mechanism for just the hostname, this would enable us to use this in conjunction with `--advertise-host` to construct an advertised address. Necessary when running behind a proxy or equivalent where internal and external ports differ.
Related to cockroachdb#1008, extending cockroachdb#9503. Also see cockroachdb#6862. The flag enables any given node to advertise it's listening port. We have a similar mechanism for just the hostname, this would enable us to use this in conjunction with `--advertise-host` to construct an advertised address. Necessary when running behind a proxy or equivalent where internal and external ports differ.
This permits users to use the --host and --port flags to control the
node's advertised external address while listening on all interfaces.
Fixes #1008.
cc @mberhault
This change is![Reviewable](https://camo.githubusercontent.com/1541c4039185914e83657d3683ec25920c672c6c5c7ab4240ee7bff601adec0b/68747470733a2f2f72657669657761626c652e696f2f7265766965775f627574746f6e2e737667)