-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Services backed by DaemonSet pods should have a hostname based network identifier #41977
Comments
@kubernetes/sig-apps-feature-requests |
Are you asking for the Pod to have the exact same name as the node? If so you could only have one DeamonSet per namespace that has this property without causing a name collision. |
It would also block cases like the first point in #31693 (comment) |
OTOH, currently we assume we always run at most one replica per node so this would help in that regard. |
@kow3ns you are right, that's borked. My main point is that there should be away how daemonset pods can be addressed per host through DNS. Considering that skydns is used, then the scheme is (as you probably know) |
Could be dsname-hostname |
Where would you use it, @Kargakis ? Eventually a flag on the daemonset spec could help to signal that the real hostname shoul dbe used as a pod hostname, i.e. |
We need to support updates of daemonsets, which would prevent pod name ==
host name. but pod name == host name + generation might be cool.
…On Mon, Feb 27, 2017 at 5:32 AM, Michail Kargakis ***@***.***> wrote:
Where would you use it, @Kargakis <https://github.com/kargakis> ?
Name of the pod.
—
You are receiving this because you are on a team that was mentioned.
Reply to this email directly, view it on GitHub
<#41977 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABG_p1uPMPr34OCutMy6nh5dZKZg8lgWks5rgqZEgaJpZM4MKFDW>
.
|
Appologies. Wrong button. |
Until we guarantee only one pod per node (which I doubt we will do) there's
no way to make podName = hostName and tolerate that.
…On Mon, Feb 27, 2017 at 2:11 PM, Fabian Deutsch ***@***.***> wrote:
Appologies. Wrong button.
—
You are receiving this because you are on a team that was mentioned.
Reply to this email directly, view it on GitHub
<#41977 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABG_p68N44Pxa3l1VzWYItuOoB90VcRFks5rgx_jgaJpZM4MKFDW>
.
|
Hi, I tried a naive approach with the following spec: apiVersion: extensions/v1beta1
kind: DaemonSet
spec:
template:
spec:
hostname:
valueFrom:
fieldRef:
fieldPath: spec.nodeName
containers:
- name: test
image: "ubuntu:16.04" but when I try to use this spec I get the following error (even if the fieldpath return a string https://github.com/kubernetes/kubernetes/blob/master/pkg/api/types.go#L1275: error: error validating "test.yaml": error validating data: expected type string, for field spec.template.spec.hostname, got map; if you choose to ignore these errors, turn validation off with --validate=false Is there a way to tell the downward API to return a string/single value? |
Let me rephrase the issue, as it might not be clear from my initial statement. Whenever a Pod is exposing a service, then the service exposed by a specific pod can be accessed using the fqdn Thus to allow a pod to access a specific service on it's own node, it would be helpful if a daemonset pod can be directly addressed using the service, namespace, and - because it's especially interesting in the daemonset case - the hostname. There could be collisions if a service is bound to more than one pod on a node. I wonder if this could be somehow avoided for the daemonset case. |
Issues go stale after 90d of inactivity. Prevent issues from auto-closing with an If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or |
Stale issues rot after 30d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or |
Would still be important to me. Might be addressed by #41442 |
Rotten issues close after 30d of inactivity. Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
There should be a way to request that the names of Pods associated to a DaemonSet will carry a pod name which is equal to the hostname.
This should make it easier to address the specific pods using kubedns.
I.e currently a podname os a DS is something like
foo-x15nb
which leads to the fqdnfoox15nb.myservice.mycluster.svc
.But to make it predictive it would be good if the hostname was used, then it's easier to lookup a psecific service on a specific host:
thefoohost.myservice.mycluster.svc
.The text was updated successfully, but these errors were encountered: