KubernetesPersistentVolumeResource
Represents a Kubernetes PersistentVolumeClaim as a first-class resource in the Aspire application model. A persistent volume resource carries the storage class, capacity, access modes, and metadata annotations needed to render a v1.Persistent at publish time. Workloads bind to it with With.
type KubernetesPersistentVolumeResource interface { Resource ResourceWithParent}Methods
WithAccessMode(accessMode PersistentVolumeAccessMode) KubernetesPersistentVolumeResourceParameters
accessMode PersistentVolumeAccessMode The access mode to add.Returns
KubernetesPersistentVolumeResource The same builder for chaining.
Returns a handle; failures surface later via Err().
WithCapacity(capacity string) KubernetesPersistentVolumeResourceParameters
capacitystringA Kubernetes quantity string (e.g. "10Gi" , "500Mi" ).Returns
KubernetesPersistentVolumeResource The same builder for chaining.
Returns a handle; failures surface later via Err().
WithCapacityParam(capacity ParameterResource) KubernetesPersistentVolumeResourceParameters
capacityParameterResource A parameter resource builder for the capacity quantity string.Returns
KubernetesPersistentVolumeResource The same builder for chaining.
Returns a handle; failures surface later via Err().
WithStorageClass(storageClassName string) KubernetesPersistentVolumeResourceParameters
storageClassName stringThe storage class name (e.g. "managed-csi" , "gp3").Returns
KubernetesPersistentVolumeResource The same builder for chaining.
Returns a handle; failures surface later via Err().
WithStorageClassParam(storageClassName ParameterResource) KubernetesPersistentVolumeResourceParameters
storageClassName ParameterResource A parameter resource builder for the storage class name.Returns
KubernetesPersistentVolumeResource The same builder for chaining.
Returns a handle; failures surface later via Err().
WithVolumeAnnotation( key string, value string,) KubernetesPersistentVolumeResourceParameters
keystringThe annotation key (e.g. "volume.beta.kubernetes.io/storage-provisioner" ).valuestringThe annotation value.Returns
KubernetesPersistentVolumeResource The same builder for chaining.
Returns a handle; failures surface later via Err().
WithVolumeAnnotationParam( key string, value ParameterResource,) KubernetesPersistentVolumeResourceParameters
keystringThe annotation key.valueParameterResource A parameter resource builder for the annotation value.Returns
KubernetesPersistentVolumeResource The same builder for chaining.
Returns a handle; failures surface later via Err().