-
Notifications
You must be signed in to change notification settings - Fork 40.1k
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
Eliminate half-baked multi-architecture support #35124
Conversation
@luxas you're the ARM ninja around, care to test? |
Jenkins GCI GKE smoke e2e failed for commit 4e121e6. Full PR test history. The magic incantation to run this job again is |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks reasonable to me with some small nits. Would love to get @luxas's take.
} | ||
} | ||
|
||
func MonoArchitectureNodeAffinity() api.NodeSelectorRequirement { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The term "Mono" here makes me think of Mono and windows and such. Perhaps just "ArchitectureNodeAffinity"? If we add multi-arch support in the future we can rename/rework this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haha, happy to rename. What about NativeArchitectureNodeAffinity()
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NativeArchitectureNodeAffinity
SGTM
@@ -206,14 +207,10 @@ func SetMasterTaintTolerations(meta *api.ObjectMeta) { | |||
meta.Annotations[api.TolerationsAnnotationKey] = string(tolerationsAnnotation) | |||
} | |||
|
|||
func SetMasterNodeAffinity(meta *api.ObjectMeta) { | |||
func SetNodeAffinity(meta *api.ObjectMeta, expr ...api.NodeSelectorRequirement) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't have documentation on public functions here and we should probably start. Can you start documenting some of this stuff as you touch it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ack.
@@ -223,6 +220,18 @@ func SetMasterNodeAffinity(meta *api.ObjectMeta) { | |||
meta.Annotations[api.AffinityAnnotationKey] = string(affinityAnnotation) | |||
} | |||
|
|||
func MasterNodeAffinity() api.NodeSelectorRequirement { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doc?
} | ||
} | ||
|
||
func MonoArchitectureNodeAffinity() api.NodeSelectorRequirement { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doc?
…ty architecture-agnostic (fix kubernetes#33916)
4e121e6
to
9703df3
Compare
@jbeda I've addressed your comments and rebased. |
Thanks! LGTM |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
1 similar comment
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
Automatic merge from submit-queue |
What this PR does / why we need it:
We have release
kubeadm
with half-baked support for clusters with nodes of different CPU architectures. The problem with the code as it stand is that user will notice pending daemonsets ofkube-proxy
for machines with architectures that they don't have. At the same time, the code as it stand did not pick up correct images for architectures it wanted to allow. Additionally, it only treatedkube-proxy
in such a way, but didn't do anything aboutkube-dns
. This removes multiple daemonesets, but ensures that whichever resources we deploy have node affinity set to the architecture native to the master. Users wishing to use mixed architectures can still create extra daemonsets via the API.Which issue this PR fixes: fixes #33916
Release note:
This change is