apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: nextcloud-apps-pvc
  namespace: nextcloud
spec:
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 1Gi
  volumeName: nextcloud-apps-pv
---
apiVersion: v1
kind: PersistentVolume
metadata:
  name: nextcloud-apps-pv
  labels:
    app: nextcloud
spec:
  capacity:
    storage: 1Gi
  accessModes:
    - ReadWriteOnce
  persistentVolumeReclaimPolicy: Retain
  claimRef:
    namespace: nextcloud
    name: nextcloud-apps-pvc
  hostPath:
    path: /var/lib/nextcloud/custom_apps
    type: DirectoryOrCreate
