update controller

This commit is contained in:
Lukasz Zajaczkowski
2025-01-20 11:38:59 +01:00
parent 7c34046e54
commit 744baa9f1d
12 changed files with 3546 additions and 1330 deletions

View File

@@ -90,6 +90,12 @@ const (
type OSArtifactStatus struct {
// +kubebuilder:default=Pending
Phase ArtifactPhase `json:"phase,omitempty"`
// +patchMergeKey=type
// +patchStrategy=merge
// +listType=map
// +listMapKey=type
Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"`
}
//+kubebuilder:object:root=true

View File

@@ -23,6 +23,7 @@ package v1alpha2
import (
batchv1 "k8s.io/api/batch/v1"
"k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
runtime "k8s.io/apimachinery/pkg/runtime"
)
@@ -32,7 +33,7 @@ func (in *OSArtifact) DeepCopyInto(out *OSArtifact) {
out.TypeMeta = in.TypeMeta
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
in.Spec.DeepCopyInto(&out.Spec)
out.Status = in.Status
in.Status.DeepCopyInto(&out.Status)
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OSArtifact.
@@ -147,6 +148,13 @@ func (in *OSArtifactSpec) DeepCopy() *OSArtifactSpec {
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *OSArtifactStatus) DeepCopyInto(out *OSArtifactStatus) {
*out = *in
if in.Conditions != nil {
in, out := &in.Conditions, &out.Conditions
*out = make([]metav1.Condition, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OSArtifactStatus.