PersistentVolumeClaims allow mounting permanent storage volumes to workloads. This validator detects a condition when a PersistentVolumeClaim is not used or referenced from workloads.
Affected Resources: Deployment, DaemonSet, StatefulSet, CronJob, Job, ReplicaSet, Pod
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: my-minio # This PVC is not used
...
kind: Deployment
spec:
template:
spec:
volumes:
- name: data
persistentVolumeClaim:
claimName: test-minio # Fix the claimName
...
Please let us know if there are other built-in validation rules you would like to see in Kubevious to detect misconfigurations and violations to best practices. Optionally, you can provide your details so we can reach out to you with follow-up questions.