feat: kubesphere 4.0 (#6115)
* feat: kubesphere 4.0 Signed-off-by: ci-bot <ci-bot@kubesphere.io> * feat: kubesphere 4.0 Signed-off-by: ci-bot <ci-bot@kubesphere.io> --------- Signed-off-by: ci-bot <ci-bot@kubesphere.io> Co-authored-by: ks-ci-bot <ks-ci-bot@example.com> Co-authored-by: joyceliu <joyceliu@yunify.com>
This commit is contained in:
committed by
GitHub
parent
b5015ec7b9
commit
447a51f08b
@@ -3,12 +3,34 @@ apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: {{ include "ks-core.serviceAccountName" . }}
|
||||
namespace: kubesphere-system
|
||||
labels:
|
||||
{{- include "ks-core.labels" . | nindent 4 }}
|
||||
{{- with .Values.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
|
||||
{{- if semverCompare ">=1.24.0-0" .Capabilities.KubeVersion.GitVersion }}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ include "ks-core.serviceAccountTokenName" . }}
|
||||
labels:
|
||||
kubesphere.io/service-account-token: ""
|
||||
{{- include "ks-core.labels" . | nindent 4 }}
|
||||
{{- if .Values.serviceAccount.annotations }}
|
||||
{{- with .Values.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
kubernetes.io/service-account.name: {{ include "ks-core.serviceAccountName" . }}
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
annotations:
|
||||
kubernetes.io/service-account.name: {{ include "ks-core.serviceAccountName" . }}
|
||||
{{- end }}
|
||||
type: kubernetes.io/service-account-token
|
||||
{{- end }}
|
||||
|
||||
---
|
||||
@@ -23,4 +45,5 @@ roleRef:
|
||||
subjects:
|
||||
- kind: ServiceAccount
|
||||
name: {{ include "ks-core.serviceAccountName" . }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
namespace: kubesphere-system
|
||||
{{- end }}
|
||||
|
||||
Reference in New Issue
Block a user