Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(charts/authentik): Support Service accounts for authentik #321

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ryanfaircloth
Copy link

This will allow the use of container secret intrfaces

@ryanfaircloth ryanfaircloth requested a review from a team as a code owner January 25, 2025 21:28
This will allow the use of container secret intrfaces
@ryanfaircloth ryanfaircloth changed the title feat: Support Service accounts for authentik feat(charts/authentik): Support Service accounts for authentik Jan 25, 2025
Copy link
Member

@rissson rissson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We already support setting a custom service account. As such I'm not inclined to accept this PR.

Comment on lines +41 to +55
{{- if .Values.server.serviceAccount.create }}
{{- if .Values.server.serviceAccount.name }}
serviceAccountName: {{ .Values.server.serviceAccount.name }}
{{- else }}
serviceAccountName: {{ template "authentik.server.fullname" . }}
{{- end }}
{{- else }}
{{- with .Values.server.imagePullSecrets | default .Values.global.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}
{{- with .Values.server.serviceAccountName }}
serviceAccountName: {{ . }}
{{- end }}
{{- end }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This might result in multiple serviceAccountName being set. Also, it removes imagePullSecrets when no service account is set

Comment on lines +41 to +52
{{- if .Values.worker.serviceAccount.create }}
{{- if .Values.worker.serviceAccount.name }}
serviceAccountName: {{ .Values.worker.serviceAccount.name }}
{{- else }}
serviceAccountName: {{ template "authentik.server.fullname" . }}
{{- end }}
{{- else }}
{{- with .Values.worker.imagePullSecrets | default .Values.global.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.worker.serviceAccountName }}
{{- end }}
{{- with .Values.server.serviceAccountName }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as the server. Also this references server.serviceAccountName although we're templating the worker deployment here

serviceAccountName: ~

serviceAccount:
create: true
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This definitely shouldn't be true by default, especially since we're using authentik-remote-cluster by default.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants