INNER CODE UNIT · Go
accounts
jaegertracing/jaeger-operator · pkg/account/main.go:13
accounts := []*corev1.ServiceAccount{}
if jaeger.Spec.Ingress.Security == v1.IngressSecurityOAuthProxy {
sa := util.Merge([]v1.JaegerCommonSpec{jaeger.Spec.Query.JaegerCommonSpec, jaeger.Spec.JaegerCommonSpec}).ServiceAccount
if len(sa) == 0 {
// if there's a service account specified for the query component, that's the one we use
// otherwise, we use a custom SA for the OAuth Proxy
accounts = append(accounts, OAuthProxy(jaeger))
}
}
return append(accounts, getMain(jaeger))
}
func getMain(jaeger *v1.Jaeger) *corev1.ServiceAccount {
trueVar := true
return &corev1.ServiceAccount{
TypeMeta: metav1.TypeMeta{
APIVersion: "v1",
Kind: "ServiceAccount",