Kubernetes Persistent Volume Claim Manifest
External
Internal
Example
apiVersion: v1 kind: PersistentVolumeClaim metadata: name: pvc1 spec: accessModes: - ReadWriteOnce storageClassName: test # volumeName: testVolume resources: requests: storage: 10Gi ...
.spec Elements
The values in the .spec section must match with the persistent volume it intends to bind with. Persistent volume's access mode, storage class name and capacity must match.
accessModes
storageClassName
Name of the StorageClass required by the claim. For a description of the claim behavior when no storage class name is present, see Persistent Volume Claims and Storage Class.
volumeName
Optionally, the persistent volume name can be specified. For a description of the claim behavior when both the storage class and the persistent volume name are specified, see Persistent Volume Claims and Storage Class.
volumeMode
'volumeMode' defines what type of volume is required by the claim. Value of "Filesystem" is implied when not included in claim spec
resources
requests
storage
A quantity specifying the minimum amount of storage required.