fix: Fix SA Secret annotation

This commit is contained in:
Bᴇʀɴᴅ Sᴄʜᴏʀɢᴇʀs 2022-11-19 14:58:19 +01:00
parent eed8d60822
commit 0a5fb9d3d4
No known key found for this signature in database
GPG key ID: BC5E2BD907F9A8EC
13 changed files with 43 additions and 43 deletions

View file

@ -3,7 +3,7 @@ apiVersion: v2
name: common
description: Function library for Helm charts
type: library
version: 1.1.1
version: 1.1.2
kubeVersion: ">=1.22.0-0"
keywords:
- common

View file

@ -5,19 +5,9 @@ Renders the serviceAccount object required by the chart.
{{- if .Values.serviceAccount.create -}}
{{- /* Create a service account secret */ -}}
{{- $_ := set .Values.secrets "sa-token" (dict "enabled" true "type" "kubernetes.io/service-account-token") -}}
{{- $serviceAccountName := include "bjw-s.common.lib.chart.names.serviceAccountName" . -}}
{{- $_ := set .Values.secrets "sa-token" (dict "enabled" true "annotations" (dict "kubernetes.io/service-account.name" $serviceAccountName) "type" "kubernetes.io/service-account-token") -}}
{{- include "bjw-s.common.class.serviceAccount" $ | nindent 0 -}}
{{- end -}}
{{- end -}}
# serviceAccount:
# # -- Specifies whether a service account should be created
# create: false
# # -- Annotations to add to the service account
# annotations: {}
# # -- The name of the service account to use.
# # If not set and create is true, a name is generated using the fullname template
# name: ""