enix / x509-certificate-exporter

A Prometheus exporter to monitor x509 certificates expiration in Kubernetes clusters or standalone
MIT License
631 stars 64 forks source link

Use Role instead of ClusterRole #298

Closed ChupaXL closed 3 months ago

ChupaXL commented 3 months ago

Hello.

I have tried to change the rbac from ClusterRole and ClusterRoleBinding to Role and RoleBinding, giving the x509-exporter the ability to only get the TLS secrets (without having the access to the root certificates) and only on some namespaces.

Currently, I did all, the serviceaccount is working, I did try to kubectl auth can-i using that specific serviceaccount and I can get the secrets. The only part that I couldn't manage is, each time I access the logs, I get 0 parsed certificates. Any help ?