apiVersion: v1
kind: PersistentVolume
metadata:
  name: opt-alertmanager
  labels:
    type: local
spec:
  storageClassName: manual
  hostPath:
    path: "/opt/alertmanager"
  capacity:
    storage: 50Gi
  accessModes:
    - ReadWriteOnce
  persistentVolumeReclaimPolicy: Retain
  claimRef:
    namespace: default
    name: opt-alertmanager
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: opt-alertmanager
spec:
  storageClassName: ""
  volumeName: "opt-alertmanager"
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 50Gi