add replicator: automatic sync tls wildcard
Deploy Casa services CI/CD Pipeline / deploy (push) Successful in 18s

This commit is contained in:
Márcio Fernandes
2026-05-29 13:30:08 +00:00
parent 101593512f
commit a88ff50fc2
3 changed files with 18 additions and 3 deletions
+5
View File
@@ -0,0 +1,5 @@
``` bash
kubectl annotate secret casa-limbosolutions-com-tls \
-n casa-limbosolutions-com \
replicator.v1.mittwald.de/replicate-to="home-assistant,node-red,lyrionmusicserver"
```
-3
View File
@@ -1,6 +1,3 @@
# Proxima iteração arranjar uma maneira de copiar os certificados entre namespaces, ainda foi a mão
# ter em atenção que ao copiar é melhor apagar anotations do cert manager para o mesmo nao ser gerido por mais do que um namespcace
apiVersion: cert-manager.io/v1
kind: Certificate
+13
View File
@@ -0,0 +1,13 @@
# replicator
Kubernetes Replicator (mittwald/kubernetesreplicator) is a lightweight controller that automatically copies Secrets and ConfigMaps between namespaces. It is ideal for sharing resources like wildcard TLS certificates generated by certmanager across multiple namespaces without manual copying.
Replicator watches for annotations on a source Secret and keeps synchronized copies updated in the target namespaces. It preserves custom metadata and removes certmanagerspecific annotations from the replicated secrets to avoid conflicts. When certmanager renews a certificate, Replicator automatically updates all replicated copies.
``` bash
helm repo add mittwald https://helm.mittwald.de
kubectl create namespace replicator
helm repo update
helm upgrade --install replicator mittwald/kubernetes-replicator \
--namespace replicator
```