Skip to content
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

Better connect-native experience in host network mode #10239

Closed
apollo13 opened this issue Mar 26, 2021 · 2 comments · Fixed by #10243
Closed

Better connect-native experience in host network mode #10239

apollo13 opened this issue Mar 26, 2021 · 2 comments · Fixed by #10243
Labels

Comments

@apollo13
Copy link
Contributor

This is a follow up to #8443 (comment)

Basically what happens currently is that connect native tasks in bridge mode get a consul socket mounted in and CONSUL_HTTP_ADDR set accordingly (+ other CONSUL_*). in host network mode it only gets the other CONSUL_* variables set. Now if consul does not listen on the default port, one has to manually set CONSUL_HTTP_ADDR. For consistency reasons (and less surprises in general) I think that the connect hook should also configure the addr in host network mode. @shoenig seems to agree (see previous link).

Now there are two options:

  • Just set CONSUL_HTTP_ADRR via nomad to the consul addr it know
  • Remove the conditional mounting that now exists and mount the socket unconditionally (in connect native mode)

Now I understand that option two is not really needed because in host network mode there should be a way to reach consul via TCP already (most likely 127.0.0.1:8500), but I am wondering if from a consistency and code complexity quality option two should be preferred… What do you think? I might be able to offer code, but I cannot decide which of the two options is the way to go.

@tgross
Copy link
Member

tgross commented Mar 26, 2021

I suspect option 1 is the best idea here @apollo13.

@tgross tgross added the theme/consul/connect Consul Connect integration label Mar 26, 2021
apollo13 added a commit to apollo13/nomad that referenced this issue Mar 26, 2021
apollo13 added a commit to apollo13/nomad that referenced this issue Mar 28, 2021
apollo13 added a commit to apollo13/nomad that referenced this issue Mar 28, 2021
@github-actions
Copy link

I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 21, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
2 participants