projectsyn / component-prometheus

Commodore component to wrap kube-prometheus jsonnet library.
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Add-on oauth-proxy kube-rbac-proxy has no service account token #55

Closed megian closed 2 years ago

megian commented 2 years ago

kube-rbac-proxy container is crashing on startup because it can't access the token /var/run/secrets/kubernetes.io/serviceaccount/token. Injecting the alertmanager serviceaccount token is disabled by default.

Override on a pod level doesn't look existing.

kubectl explain Alertmanager.spec

After set automountServiceAccountToken: true in the serviceaccount, everything works.

Steps to Reproduce the Problem

  1. Use a Kubernetes 1.23 cluster
  2. Enable the Add-on oauth-proxy

Actual Behavior

kube-rbac-proxy has no token available

Expected Behavior

kube-rbac-proxy has access to the injected /var/run/secrets/kubernetes.io/serviceaccount/token