mirror of
https://github.com/vmware-tanzu/velero.git
synced 2026-08-15 11:46:06 +00:00
Add SkipDefaultResourceModifier field to RestoreSpec
Add *bool field following existing RestoreSpec conventions (RestorePVs, PreserveNodePorts, IncludeClusterResources). When true, the server default resource modifier is skipped for this restore. Signed-off-by: Shubham Pampattiwar <spampatt@redhat.com>
This commit is contained in:
@@ -467,6 +467,14 @@ spec:
|
||||
from. If specified, and BackupName is empty, Velero will restore
|
||||
from the most recent successful backup created from this schedule.
|
||||
type: string
|
||||
skipDefaultResourceModifier:
|
||||
description: |-
|
||||
SkipDefaultResourceModifier controls whether the server-configured default
|
||||
resource modifier is applied to this restore.
|
||||
When true, the default modifier is skipped even if configured on the server.
|
||||
Has no effect when a per-restore ResourceModifier is specified.
|
||||
nullable: true
|
||||
type: boolean
|
||||
uploaderConfig:
|
||||
description: UploaderConfig specifies the configuration for the restore.
|
||||
nullable: true
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -135,6 +135,14 @@ type RestoreSpec struct {
|
||||
// +nullable
|
||||
ResourcePolicy *corev1api.TypedLocalObjectReference `json:"resourcePolicy,omitempty"`
|
||||
|
||||
// SkipDefaultResourceModifier controls whether the server-configured default
|
||||
// resource modifier is applied to this restore.
|
||||
// When true, the default modifier is skipped even if configured on the server.
|
||||
// Has no effect when a per-restore ResourceModifier is specified.
|
||||
// +optional
|
||||
// +nullable
|
||||
SkipDefaultResourceModifier *bool `json:"skipDefaultResourceModifier,omitempty"`
|
||||
|
||||
// UploaderConfig specifies the configuration for the restore.
|
||||
// +optional
|
||||
// +nullable
|
||||
|
||||
@@ -1427,6 +1427,11 @@ func (in *RestoreSpec) DeepCopyInto(out *RestoreSpec) {
|
||||
*out = new(corev1.TypedLocalObjectReference)
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
if in.SkipDefaultResourceModifier != nil {
|
||||
in, out := &in.SkipDefaultResourceModifier, &out.SkipDefaultResourceModifier
|
||||
*out = new(bool)
|
||||
**out = **in
|
||||
}
|
||||
if in.UploaderConfig != nil {
|
||||
in, out := &in.UploaderConfig, &out.UploaderConfig
|
||||
*out = new(UploaderConfigForRestore)
|
||||
|
||||
Reference in New Issue
Block a user