-
Notifications
You must be signed in to change notification settings - Fork 35
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: hostname not populated for /etc/hosts in bridge networks. #105
base: master
Are you sure you want to change the base?
Conversation
I am trying to address Issue #103 in
Any pointers in how to integrate (2) [https://github.com/hashicorp/nomad/pull/10766] in |
@tgross @notnoop The
However, if I switch to
This is the job I am using:
|
Thanks @shishir-a412ed for the ping. I'm investigating the expected network invariants here and will follow up with concrete suggestions (or a proposed changes). So /etc/hosts should be populated with the hostname for each container. My understanding is that Docker required some custom handling that necessities having Docker create the network using a pause container and joining the task containers with the pause container network namespace. In that setup, all containers will have the same hostname, so we chose to create a single Examining containerd behavior, it seems we don't have the same limitation, and each container has its own hostname despite being in the same namespace, and without requiring a pause container. If that works, then we probably should have a new unique So the question I have is: Does having having containers with different hostnames yet in the same namespace and with same ip address has adverse effects workloads? Let me know if you have any opinions, I'll double check and follow up. |
My understanding from when I did the Docker implementation and looked at As for the impact of multiple hostnames within a single network namespace, I suspect where things will get weird is in application metrics, because tasks that ship with metrics libraries will report different container hostnames, none of which will match even though they're all in the same alloc. (Also, just a heads up @shishir-a412ed that I'm not at HashiCorp anymore, although I'm always happy to take a look at what y'all are up to!) |
@notnoop Apologies for the delayed response. After thinking a bit more about this, I am still convoluted on what would be the best way to address this? In the docker driver, a As you mentioned this is not a constraint in the I think my question was specific to, when I call As in, If the task driver is responsible for creating the @tgross Sad to see you go. Thank you for all the contributions and quick responses/reviews. Being a maintainer is hard! and you did a phenomenal job. Looking forward to what you create next! |
8eb8bf9
to
298308d
Compare
Signed-off-by: Shishir Mahajan <[email protected]>
298308d
to
8c75b18
Compare
@shishir-a412ed any updates on this? |
Signed-off-by: Shishir Mahajan [email protected]