operator: reconcile kubernetesClusterVersion

This commit is contained in:
Leonard Cohnen 2023-01-06 12:08:25 +01:00 committed by 3u13r
parent 8c5e41b865
commit 2700d5182b
19 changed files with 521 additions and 33 deletions

View file

@ -35,6 +35,8 @@ type NodeVersionStatus struct {
Heirs []corev1.ObjectReference `json:"heirs,omitempty"`
// Mints is a list of up to date nodes that will become heirs.
Mints []corev1.ObjectReference `json:"mints,omitempty"`
// AwaitingAnnotation is a list of nodes that are waiting for the operator to annotate them.
AwaitingAnnotation []corev1.ObjectReference `json:"awaitingAnnotation,omitempty"`
// Pending is a list of pending nodes (joining or leaving the cluster).
Pending []corev1.ObjectReference `json:"pending,omitempty"`
// Obsolete is a list of obsolete nodes (nodes that have been created by the operator but are no longer needed).
@ -45,6 +47,8 @@ type NodeVersionStatus struct {
Budget uint32 `json:"budget"`
// Conditions represent the latest available observations of an object's state
Conditions []metav1.Condition `json:"conditions"`
// ActiveClusterVersionUpgrade indicates whether the cluster is currently upgrading.
ActiveClusterVersionUpgrade bool `json:"activeclusterversionupgrade"`
}
//+kubebuilder:object:root=true

View file

@ -302,6 +302,11 @@ func (in *NodeVersionStatus) DeepCopyInto(out *NodeVersionStatus) {
*out = make([]v1.ObjectReference, len(*in))
copy(*out, *in)
}
if in.AwaitingAnnotation != nil {
in, out := &in.AwaitingAnnotation, &out.AwaitingAnnotation
*out = make([]v1.ObjectReference, len(*in))
copy(*out, *in)
}
if in.Pending != nil {
in, out := &in.Pending, &out.Pending
*out = make([]v1.ObjectReference, len(*in))