apiVersion: v1
kind: PersistentVolume
metadata:
  name: mongodb-pv
  labels:
    app: mongodb-pv
spec:
  capacity:
    storage: 1Gi
  accessModes:
  - ReadWriteOnce # single client, R+W
  - ReadOnlyMany # multiple clients, R
  # options after PVC release: Retain, Recycle, Delete
  persistentVolumeReclaimPolicy: Retain
  hostPath: # persistent volume backing object
    path: /tmp/mongodb
