From 3f37d7db9f622029d7f62bd6885d19e8eb67d2ca Mon Sep 17 00:00:00 2001 From: RohanKumarMainali Date: Thu, 26 Dec 2024 16:00:37 +0545 Subject: [PATCH 1/3] fix(): add enable auto eviction in cluster Signed-off-by: RohanKumarMainali --- .../v1alpha1/zz_generated.deepcopy.go | 18 ++++++++++++++++++ pkg/worker/v1alpha1/zz_generated.deepcopy.go | 1 + 2 files changed, 19 insertions(+) diff --git a/pkg/controller/v1alpha1/zz_generated.deepcopy.go b/pkg/controller/v1alpha1/zz_generated.deepcopy.go index 0490636..0ff21e2 100644 --- a/pkg/controller/v1alpha1/zz_generated.deepcopy.go +++ b/pkg/controller/v1alpha1/zz_generated.deepcopy.go @@ -209,6 +209,7 @@ func (in *ExternalGatewayConfig) DeepCopyInto(out *ExternalGatewayConfig) { *out = make([]string, len(*in)) copy(*out, *in) } + out.VPCServiceAccess = in.VPCServiceAccess } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExternalGatewayConfig. @@ -452,6 +453,23 @@ func (in *QOSProfile) DeepCopy() *QOSProfile { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ServiceAccess) DeepCopyInto(out *ServiceAccess) { + *out = *in + out.Ingress = in.Ingress + out.Egress = in.Egress +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServiceAccess. +func (in *ServiceAccess) DeepCopy() *ServiceAccess { + if in == nil { + return nil + } + out := new(ServiceAccess) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ServiceAccount) DeepCopyInto(out *ServiceAccount) { *out = *in diff --git a/pkg/worker/v1alpha1/zz_generated.deepcopy.go b/pkg/worker/v1alpha1/zz_generated.deepcopy.go index bda9ca3..0a406a5 100644 --- a/pkg/worker/v1alpha1/zz_generated.deepcopy.go +++ b/pkg/worker/v1alpha1/zz_generated.deepcopy.go @@ -75,6 +75,7 @@ func (in *ExternalGatewayConfig) DeepCopyInto(out *ExternalGatewayConfig) { out.Ingress = in.Ingress out.Egress = in.Egress out.NsIngress = in.NsIngress + out.VPCServiceAccess = in.VPCServiceAccess } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExternalGatewayConfig. From 062801cefed9f438114d81406720110ccc88d505 Mon Sep 17 00:00:00 2001 From: RohanKumarMainali Date: Thu, 26 Dec 2024 16:30:23 +0545 Subject: [PATCH 2/3] fix(): add enable auto eviction in cluster Signed-off-by: RohanKumarMainali --- pkg/controller/v1alpha1/cluster_types.go | 2 ++ pkg/controller/v1alpha1/project_types.go | 2 ++ 2 files changed, 4 insertions(+) diff --git a/pkg/controller/v1alpha1/cluster_types.go b/pkg/controller/v1alpha1/cluster_types.go index 63efbe8..2c67a9b 100644 --- a/pkg/controller/v1alpha1/cluster_types.go +++ b/pkg/controller/v1alpha1/cluster_types.go @@ -57,6 +57,8 @@ type ClusterSpec struct { NetworkInterface string `json:"networkInterface,omitempty"` //put in an object ClusterProperty ClusterProperty `json:"clusterProperty,omitempty"` + // EnableAutoEviction is a flag to enable auto eviction feature for the given cluster + EnableAutoEviction bool `json:"enableAutoEviction,omitempty"` } type ClusterProperty struct { diff --git a/pkg/controller/v1alpha1/project_types.go b/pkg/controller/v1alpha1/project_types.go index 114a6c7..08be4a4 100644 --- a/pkg/controller/v1alpha1/project_types.go +++ b/pkg/controller/v1alpha1/project_types.go @@ -24,6 +24,8 @@ import ( type ProjectSpec struct { // ServiceAccount is a field of Project. Edit project_types.go to remove/update ServiceAccount ServiceAccount `json:"serviceAccount,omitempty"` + // If defaultSliceCreation is true, then the default slice will be created + DefaultSliceCreation bool `json:"defaultSliceCreation,omitempty"` } // ServiceAccount defines the field of ProjectSpec From b3fd73e928d376bd9925c0ad4bc11020ab530f6e Mon Sep 17 00:00:00 2001 From: RohanKumarMainali Date: Fri, 10 Jan 2025 15:50:13 +0545 Subject: [PATCH 3/3] fix(): add requeueOnFailure field Signed-off-by: RohanKumarMainali --- pkg/controller/v1alpha1/cluster_types.go | 1 + pkg/controller/v1alpha1/zz_generated.deepcopy.go | 7 ++++--- pkg/worker/v1alpha1/zz_generated.deepcopy.go | 1 - 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/pkg/controller/v1alpha1/cluster_types.go b/pkg/controller/v1alpha1/cluster_types.go index 2c67a9b..8619483 100644 --- a/pkg/controller/v1alpha1/cluster_types.go +++ b/pkg/controller/v1alpha1/cluster_types.go @@ -59,6 +59,7 @@ type ClusterSpec struct { ClusterProperty ClusterProperty `json:"clusterProperty,omitempty"` // EnableAutoEviction is a flag to enable auto eviction feature for the given cluster EnableAutoEviction bool `json:"enableAutoEviction,omitempty"` + RequeueOnFailure bool `json:"requeueOnFailure,omitempty"` } type ClusterProperty struct { diff --git a/pkg/controller/v1alpha1/zz_generated.deepcopy.go b/pkg/controller/v1alpha1/zz_generated.deepcopy.go index 0ff21e2..f195839 100644 --- a/pkg/controller/v1alpha1/zz_generated.deepcopy.go +++ b/pkg/controller/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright (c) 2022 Avesha, Inc. All rights reserved. SPDX-License-Identifier: Apache-2.0 @@ -1013,7 +1012,8 @@ func (in *VpnKeyRotationSpec) DeepCopyInto(out *VpnKeyRotationSpec) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = make([]string, len(*in)) copy(*out, *in) } @@ -1063,7 +1063,8 @@ func (in *VpnKeyRotationStatus) DeepCopyInto(out *VpnKeyRotationStatus) { if val == nil { (*out)[key] = nil } else { - in, out := &val, &outVal + inVal := (*in)[key] + in, out := &inVal, &outVal *out = make([]StatusOfKeyRotation, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) diff --git a/pkg/worker/v1alpha1/zz_generated.deepcopy.go b/pkg/worker/v1alpha1/zz_generated.deepcopy.go index 0a406a5..5cd610f 100644 --- a/pkg/worker/v1alpha1/zz_generated.deepcopy.go +++ b/pkg/worker/v1alpha1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright (c) 2022 Avesha, Inc. All rights reserved. SPDX-License-Identifier: Apache-2.0