Ah, you're right, thanks for the correction.
On Wed, Feb 15, 2017 at 4:43 AM, Łukasz Oleś <lukaszo...@gmail.com> wrote: > > > On Sunday, February 12, 2017 at 10:55:42 AM UTC+1, David Oppenheimer wrote: >> >> [moving kubernetes-dev back to bcc] >> >> >> On Sun, Feb 12, 2017 at 1:11 AM, <krma...@gmail.com> wrote: >> >>> Hi David >>> Thanks. You mean both nodeSelector and node affinity right. As per this >>> doc https://kubernetes.io/docs/admin/daemons/#running-pods- >>> on-only-some-nodes, both nodeSelector and node affinity work. >>> >> >> I believe that documentation is wrong. More specifically, the >> spec.template.spec.nodeSelector part is correct, but the >> .spec.template.metadata.annotations part is wrong (not yet supported for >> DaemonSet). The predicate functions respected by DaemonSet are only the >> ones listed here: https://github.com/kubernetes/kubernetes/blob/4ed86f5d >> 4649ff9e612ad945b38ce9db147daaef/plugin/pkg/scheduler/ >> algorithm/predicates/predicates.go#L840 >> > > GeneralPredicates checks node affinity here https://github.com/kubernetes/ > kubernetes/blob/4ed86f5d4649ff9e612ad945b38ce9db147daaef/plugin/pkg/ > scheduler/algorithm/predicates/predicates.go#L572 > so DaemonSet also supports node affinity. > > When I was changing DaemonSets to use GeneralPredicates I also added a > unit test to check node affinity: https://github.com/kubernetes/ > kubernetes/blob/master/pkg/controller/daemon/daemoncontroller_test.go#L608 > > > Regards > > -- > You received this message because you are subscribed to the Google Groups > "Kubernetes developer/contributor discussion" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to kubernetes-dev+unsubscr...@googlegroups.com. > To post to this group, send email to kubernetes-...@googlegroups.com. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/kubernetes-dev/07d3a762-b194-4504-8594-1ffa72b9b328% > 40googlegroups.com > <https://groups.google.com/d/msgid/kubernetes-dev/07d3a762-b194-4504-8594-1ffa72b9b328%40googlegroups.com?utm_medium=email&utm_source=footer> > . > > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Kubernetes user discussion and Q&A" group. To unsubscribe from this group and stop receiving emails from it, send an email to kubernetes-users+unsubscr...@googlegroups.com. To post to this group, send email to kubernetes-users@googlegroups.com. Visit this group at https://groups.google.com/group/kubernetes-users. For more options, visit https://groups.google.com/d/optout.