update osartifact helm chart

This commit is contained in:
Sebastian Florek 2025-01-17 17:55:30 +01:00
parent bd0806c50d
commit 7c34046e54
No known key found for this signature in database
GPG Key ID: DBC7C083B0200A0F
2 changed files with 9 additions and 3 deletions

View File

@ -2,4 +2,4 @@ apiVersion: v2
name: osartifact name: osartifact
description: A Helm chart for OSArtifact CRD deployment description: A Helm chart for OSArtifact CRD deployment
type: application type: application
version: 0.2.0 version: 0.3.0

View File

@ -1,6 +1,11 @@
{{ $tokenSecret := (lookup "v1" "Secret" .Release.Namespace .Values.tokenSecret.name) }} {{ $tokenSecret := (lookup "v1" "Secret" .Release.Namespace .Values.tokenSecret.name) }}
{{ $passwordSecret := (lookup "v1" "Secret" .Release.Namespace .Values.passwordSecret.name) }} {{ $passwordSecret := (lookup "v1" "Secret" .Release.Namespace .Values.passwordSecret.name) }}
{{- if and $tokenSecret $passwordSecret }}
{{ $token := index $tokenSecret.data .Values.tokenSecret.key | b64dec }}
{{ $password := index $passwordSecret.data .Values.passwordSecret.key | b64dec }}
kind: Secret kind: Secret
apiVersion: v1 apiVersion: v1
metadata: metadata:
@ -12,7 +17,7 @@ stringData:
users: users:
- name: {{ .Values.username }} - name: {{ .Values.username }}
passwd: {{ index $passwordSecret .Values.passwordSecret.key }} passwd: {{ $password }}
{{- with .Values.defaultUser }} {{- with .Values.defaultUser }}
groups: [ groups: [
{{- range .groups -}} {{- range .groups -}}
@ -68,10 +73,11 @@ stringData:
{{- end }} {{- end }}
plural: plural:
token: {{ index $tokenSecret .Values.tokenSecret.key }} token: {{ $token }}
url: {{ .Values.url }} url: {{ .Values.url }}
{{- if .Values.extraUserCloudConfig }} {{- if .Values.extraUserCloudConfig }}
{{ .Values.extraCloudConfig | toYaml | nindent 4 }} {{ .Values.extraCloudConfig | toYaml | nindent 4 }}
{{- end }} {{- end }}
{{- end}}