Description
Summary
The Coder Helm chart lacks fine-grained control for spreading Coder control plane Pods across failure domains such as region or zone and should be enabled by supporting topologySpreadConstraints
.
https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/
Motivation
To ensure that the control plane is highly available, it should be distributed across regions/zones. At present, the Coder control plane Deployment
supports tolerations
and affinity
which can be leveraged to influence how Pods are scheduled, however, podAntiAffinity
's single-factor targeting either doesn't guarantee spread across regions/zones or creates scheduling bottlenecks depending on if you choose preferredDuringSchedulingIgnoredDuringExecution
or requiredDuringSchedulingIgnoredDuringExecution
.
Topology spread constraints are considered a best practices way to accomplish this with features like:
minDomains
maxSkew
whenUnsatisfiable