mirror of
https://github.com/tailscale/tailscale.git
synced 2025-10-09 08:01:31 +00:00
cmd/k8s-operator,k8s-operator: proxyclass affinity (#11862)
add ability to set affinity rules to proxyclass Updates#11861 Signed-off-by: Lee Briggs <lee@leebriggs.co.uk>
This commit is contained in:
1365
k8s-operator/api.md
1365
k8s-operator/api.md
File diff suppressed because it is too large
Load Diff
@@ -94,6 +94,11 @@ type Pod struct {
|
||||
// https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/#syntax-and-character-set
|
||||
// +optional
|
||||
Annotations map[string]string `json:"annotations,omitempty"`
|
||||
// Proxy Pod's affinity rules.
|
||||
// By default, the Tailscale Kubernetes operator does not apply any affinity rules.
|
||||
// https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#affinity
|
||||
// +optional
|
||||
Affinity *corev1.Affinity `json:"affinity,omitempty"`
|
||||
// Configuration for the proxy container running tailscale.
|
||||
// +optional
|
||||
TailscaleContainer *Container `json:"tailscaleContainer,omitempty"`
|
||||
|
@@ -195,6 +195,11 @@ func (in *Pod) DeepCopyInto(out *Pod) {
|
||||
(*out)[key] = val
|
||||
}
|
||||
}
|
||||
if in.Affinity != nil {
|
||||
in, out := &in.Affinity, &out.Affinity
|
||||
*out = new(v1.Affinity)
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
if in.TailscaleContainer != nil {
|
||||
in, out := &in.TailscaleContainer, &out.TailscaleContainer
|
||||
*out = new(Container)
|
||||
|
Reference in New Issue
Block a user