From e483e8ab40c25e462416d25111bc94983fc90eee Mon Sep 17 00:00:00 2001 From: Dan Prince Date: Tue, 15 Oct 2024 21:44:47 -0400 Subject: [PATCH] Drop more VolSource Probably not likely we'll be using these: PhotonPersistentDisk Projected Ephemeral --- modules/storage/storage.go | 13 ------------- modules/storage/zz_generated.deepcopy.go | 15 --------------- 2 files changed, 28 deletions(-) diff --git a/modules/storage/storage.go b/modules/storage/storage.go index e5ae8ba7..6e8f74ee 100644 --- a/modules/storage/storage.go +++ b/modules/storage/storage.go @@ -78,10 +78,6 @@ type VolumeSource struct { // configMap represents a configMap that should populate this volume // +optional ConfigMap *corev1.ConfigMapVolumeSource `json:"configMap,omitempty" protobuf:"bytes,19,opt,name=configMap"` - // photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine - PhotonPersistentDisk *corev1.PhotonPersistentDiskVolumeSource `json:"photonPersistentDisk,omitempty" protobuf:"bytes,23,opt,name=photonPersistentDisk"` - // projected items for all in one resources secrets, configmaps, and downward API - Projected *corev1.ProjectedVolumeSource `json:"projected,omitempty" protobuf:"bytes,26,opt,name=projected"` // scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. // +optional ScaleIO *corev1.ScaleIOVolumeSource `json:"scaleIO,omitempty" protobuf:"bytes,25,opt,name=scaleIO"` @@ -91,12 +87,6 @@ type VolumeSource struct { // csi (Container Storage Interface) represents ephemeral storage that is handled by certain external CSI drivers (Beta feature). // +optional CSI *corev1.CSIVolumeSource `json:"csi,omitempty" protobuf:"bytes,28,opt,name=csi"` - // ephemeral represents a volume that is handled by a cluster storage driver. - // The volume's lifecycle is tied to the pod that defines it - it will be created before the pod starts, - // and deleted when the pod is removed. - // - // +optional - Ephemeral *corev1.EphemeralVolumeSource `json:"ephemeral,omitempty" protobuf:"bytes,29,opt,name=ephemeral"` } // Volume our slimmed down version of Volume @@ -165,11 +155,8 @@ func ConvertVolumeSource(v *VolumeSource) corev1.VolumeSource { DownwardAPI: v.DownwardAPI, FC: v.FC, ConfigMap: v.ConfigMap, - PhotonPersistentDisk: v.PhotonPersistentDisk, - Projected: v.Projected, ScaleIO: v.ScaleIO, StorageOS: v.StorageOS, CSI: v.CSI, - Ephemeral: v.Ephemeral, } } diff --git a/modules/storage/zz_generated.deepcopy.go b/modules/storage/zz_generated.deepcopy.go index 06834f77..59603de0 100644 --- a/modules/storage/zz_generated.deepcopy.go +++ b/modules/storage/zz_generated.deepcopy.go @@ -128,16 +128,6 @@ func (in *VolumeSource) DeepCopyInto(out *VolumeSource) { *out = new(v1.ConfigMapVolumeSource) (*in).DeepCopyInto(*out) } - if in.PhotonPersistentDisk != nil { - in, out := &in.PhotonPersistentDisk, &out.PhotonPersistentDisk - *out = new(v1.PhotonPersistentDiskVolumeSource) - **out = **in - } - if in.Projected != nil { - in, out := &in.Projected, &out.Projected - *out = new(v1.ProjectedVolumeSource) - (*in).DeepCopyInto(*out) - } if in.ScaleIO != nil { in, out := &in.ScaleIO, &out.ScaleIO *out = new(v1.ScaleIOVolumeSource) @@ -153,11 +143,6 @@ func (in *VolumeSource) DeepCopyInto(out *VolumeSource) { *out = new(v1.CSIVolumeSource) (*in).DeepCopyInto(*out) } - if in.Ephemeral != nil { - in, out := &in.Ephemeral, &out.Ephemeral - *out = new(v1.EphemeralVolumeSource) - (*in).DeepCopyInto(*out) - } } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VolumeSource.