mittwald/kubernetes-replicator

Annotations are not replicated

gcaracuel opened this issue · 1 comments

Describe the bug
Using push-based replication annotations are not replicate from source to destination.
Of course replicator.v1.mittwald.de/replicate-to must be exempt here.

To Reproduce
Create a Secret/ConfigMap extra annotations non related to kubernetes-replicator.
When using push-based replication the source annotations won't reach the destination secret.

Expected behavior
When using push-based replication over a Secret/ConfigMap that has extra annotations non related to kubernetes-replicator, those annotations must be copied over to destination Secret/ConfigMap

Environment:

  • Kubernetes version: 1.19.14
  • kubernetes-replicator version: 2.7.0

Additional context
To add extra context on this task I am facing it when using ArgoCD or any other GitOps tool.
I have an operator (Kafka/Strimzi) which generates a Secret in a namespace which I want later to replicate to another namespace so it can be used there.
This operator allows the Secret creation to be done adding some annotations, actually this is the feature that allows me to set replicator.v1.mittwald.de/replicate-to but I would like also to add there argocd.argoproj.io/sync-options: Prune=false so ArgoCD syncs does not want to prune the destination secret every single time avoiding the sync loop.

Mitigation plan on my end is to avoid push-based replication and step into pull-based replication but of course this complicates my setup adding the need to limit destination namespace and so on.

There has not been any activity to this issue in the last 14 days. It will automatically be closed after 7 more days. Remove the stale label to prevent this.