Setting custom annotations for PVC

Hi all,

I want to deploy percona mongodb operator with argocd (gitops approach). This means that argocd pulls the helm config from our git repository and applies it to the k8s cluster.

However, when certain kubernetes ressources are not in git but generated automatically like a PVC, I need to tell argocd to ignore those. Otherwise they might get pruned/deleted during sync process.

For this, I need to set an annotation on the PVC created by mongodb operator (like in this example from another operator: Kafka pvcs out of sync in Argo · Discussion #7205 · strimzi/strimzi-kafka-operator · GitHub)
However, looking on the custom resource options page (Custom Resource options - Percona Operator for MongoDB) I don’t see an option to set custom annotations on PVCs initated by percona mongo operator.
Is this true? Would it be possible to develop such feature if missing?

1 Like