Difference between revisions of "Create a PersistentVolumeClaim"

From wikieduonline
Jump to navigation Jump to search
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
  
 
  pd-xfs-pvc.yaml
 
  pd-xfs-pvc.yaml
<pre>
+
 
apiVersion: v1
+
apiVersion: v1
kind: PersistentVolumeClaim
+
[[kind: PersistentVolumeClaim]]
metadata:
+
metadata:
  name: xfs-pvc
+
  name: xfs-pvc
spec:
+
spec:
  storageClassName: xfs-class
+
  [[storageClassName]]: xfs-class
  accessModes:
+
  accessModes:
    - ReadWriteOnce
+
    - ReadWriteOnce
  resources:
+
  resources:
    requests:
+
    requests:
      storage: 10Gi
+
      storage: 10Gi
</pre>
 
  
 
  kubectl apply -f pd-xfs-pvc.yaml
 
  kubectl apply -f pd-xfs-pvc.yaml
  
  
 +
 +
{{kind: PersistentVolumeClaim}}
 +
 +
== Related ==
 +
* [[Kubernetes Persistent Volumes (PV)]]
  
 
== See also ==
 
== See also ==
 +
* {{PVC}}
 
* {{Kubernetes storage}}
 
* {{Kubernetes storage}}
  
 
[[Category:K8s]]
 
[[Category:K8s]]

Latest revision as of 11:52, 2 February 2024

Advertising: