You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: call TokenRequest API when service account token secret is missing (#3377)
* fix: call TokenRequest API when service account token secret is missing
Beyond Kubernetes 1.22, the service account token secret is not
automatically, created. Therefore, when OLM is not able to find the
service account token secret, it should request one from the k8s api
server.
Ref: https://kubernetes.io/docs/reference/access-authn-authz/service-accounts-admin/#manual-secret-management-for-serviceaccounts
Signed-off-by: Edmund Ochieng <[email protected]>
* fix: return error
Signed-off-by: Edmund Ochieng <[email protected]>
* handle error when creating sa token from TokenRequest API fails
Signed-off-by: Edmund Ochieng <[email protected]>
* move return from inner loop
Move the return to line 48. This will ensure a value is returned whether
we successully create a service account token from the TokenRequest API or get an error
Signed-off-by: Edmund Ochieng <[email protected]>
---------
Signed-off-by: Edmund Ochieng <[email protected]>
0 commit comments