mirror of
https://github.com/cozystack/cozystack.git
synced 2026-11-23 21:25:44 +09:00
cert-manager is deployed with enableCertificateOwnerRef disabled, so removing a Certificate leaves the Secret it issued in place. Uninstalling an instance that used managed TLS therefore left <release>-ca-tls, which holds the CA signing key, and <release>-tls, which holds the server key, sitting in a namespace the tenant shares with its other applications, for as long as the namespace exists. The chart already had the mechanism: the post-delete hook deletes the operator-generated password Secrets by name under an RBAC rule scoped to exactly those names. Add these two to both lists. -ca-bundle stays out — the operator gives it an ownerRef, so Kubernetes collects it, and naming it here would widen the grant for nothing. Signed-off-by: Aleksei Sviridkin <f@lex.la>
How to test packages local
cd packages/core/installer
make image-cozystack REGISTRY=YOUR_CUSTOM_REGISTRY
make apply
kubectl delete po -l app=source-controller -n cozy-fluxcd