Difference between revisions of "Kubernetes Persistent volumes (PV)"

From wikieduonline
Jump to navigation Jump to search
Line 3: Line 3:
 
* https://kubernetes.io/docs/concepts/storage/persistent-volumes/
 
* https://kubernetes.io/docs/concepts/storage/persistent-volumes/
  
<pre>
+
 
apiVersion: v1
+
apiVersion: v1
kind: PersistentVolume
+
[[kind: PersistentVolume]]
metadata:
+
metadata:
  name: pv0003
+
  name: pv0003
spec:
+
spec:
  capacity:
+
  capacity:
    storage: 5Gi
+
    storage: 5Gi
  volumeMode: Filesystem
+
  volumeMode: Filesystem
  accessModes:
+
  accessModes:
    - ReadWriteOnce
+
    - ReadWriteOnce
  persistentVolumeReclaimPolicy: Recycle
+
  persistentVolumeReclaimPolicy: Recycle
  storageClassName: slow
+
  storageClassName: slow
  mountOptions:
+
  mountOptions:
    - hard
+
    - hard
    - nfsvers=4.1
+
    - nfsvers=4.1
  nfs:
+
  nfs:
    path: /tmp
+
    path: /tmp
    server: 172.17.0.2
+
    server: 172.17.0.2
</pre>
+
 
  
  

Revision as of 11:23, 2 February 2024

Advertising: