feat: create extensionVersions by depth (#6286)
* feat: create extensionVersions by depth * Apply suggestions from code review Signed-off-by: hongming <coder.scala@gmail.com> * Apply suggestions from code review Signed-off-by: hongming <coder.scala@gmail.com> --------- Signed-off-by: hongming <coder.scala@gmail.com> Co-authored-by: joyceliu <joyceliu@yunify.com> Co-authored-by: hongming <coder.scala@gmail.com>
This commit is contained in:
@@ -40,3 +40,7 @@ const (
|
||||
ExecutorUpgradeHookImageAnnotation = "executor-hook-image.kubesphere.io/upgrade"
|
||||
ExecutorUninstallHookImageAnnotation = "executor-hook-image.kubesphere.io/uninstall"
|
||||
)
|
||||
|
||||
const (
|
||||
DefaultRepositoryDepth = 3
|
||||
)
|
||||
|
||||
@@ -29,6 +29,9 @@ type RepositorySpec struct {
|
||||
CABundle string `json:"caBundle,omitempty"`
|
||||
// --insecure-skip-tls-verify. default false
|
||||
Insecure bool `json:"insecure,omitempty"`
|
||||
// The maximum number of synchronized versions for each extension. A value of 0 indicates that all versions will be synchronized. The default is 3.
|
||||
// +optional
|
||||
Depth *int `json:"depth,omitempty"`
|
||||
}
|
||||
|
||||
type RepositoryStatus struct {
|
||||
|
||||
@@ -754,6 +754,11 @@ func (in *RepositorySpec) DeepCopyInto(out *RepositorySpec) {
|
||||
*out = new(UpdateStrategy)
|
||||
**out = **in
|
||||
}
|
||||
if in.Depth != nil {
|
||||
in, out := &in.Depth, &out.Depth
|
||||
*out = new(int)
|
||||
**out = **in
|
||||
}
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RepositorySpec.
|
||||
|
||||
Reference in New Issue
Block a user