fix(chart): access subchart generated values properly
This commit is contained in:
@@ -179,24 +179,22 @@ spec:
|
||||
|
||||
# redis
|
||||
- name: REDIS_HOST
|
||||
{{- if .Values.externalValkey.existingSecret }}
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.externalValkey.existingSecret }}
|
||||
name: {{ .Values.externalValkey.existingSecret }}
|
||||
key: {{ .Values.externalValkey.existingSecretKeys.host }}
|
||||
{{- else }}
|
||||
name: pixelfed-valkey
|
||||
key: host
|
||||
value: {{ printf "%s-primary" (.Values.valkey.fullnameOverride) }}
|
||||
{{- end }}
|
||||
- name: REDIS_PORT
|
||||
{{- if .Values.externalValkey.existingSecret }}
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.externalValkey.existingSecret }}
|
||||
name: {{ .Values.externalValkey.existingSecret }}
|
||||
key: {{ .Values.externalValkey.existingSecretKeys.port }}
|
||||
{{- else }}
|
||||
name: pixelfed-valkey
|
||||
key: port
|
||||
value: {{ .Values.valkey.primary.service.ports.valkey | quote }}
|
||||
{{- end }}
|
||||
- name: REDIS_PASSWORD
|
||||
valueFrom:
|
||||
@@ -204,9 +202,12 @@ spec:
|
||||
{{- if .Values.externalValkey.existingSecret }}
|
||||
name: {{ .Values.externalValkey.existingSecret }}
|
||||
key: {{ .Values.externalValkey.existingSecretKeys.password }}
|
||||
{{- else }}
|
||||
name: pixelfed-valkey
|
||||
{{- else if .Values.valkey.auth.existingSecret }}
|
||||
name: {{ .Values.valkey.auth.existingSecret }}
|
||||
key: password
|
||||
{{- else }}
|
||||
name: {{ .Values.valkey.fullnameOverride }}
|
||||
key: valkey-password
|
||||
{{- end }}
|
||||
|
||||
# mail
|
||||
@@ -263,54 +264,53 @@ spec:
|
||||
- name: DB_CONNECTION
|
||||
value: {{ .Values.externalDatabase.connection }}
|
||||
- name: DB_HOST
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
name: {{ .Values.externalDatabase.existingSecret }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.username }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.host }}
|
||||
{{- else }}
|
||||
name: pixelfed-database
|
||||
key: host
|
||||
value: {{ .Values.postgresql.fullnameOverride }}
|
||||
{{- end }}
|
||||
- name: DB_USERNAME
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
name: {{ .Values.externalDatabase.existingSecret }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.username }}
|
||||
{{- else }}
|
||||
name: pixelfed-database
|
||||
key: username
|
||||
value: postgres
|
||||
{{- end }}
|
||||
- name: DB_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
name: {{ .Values.externalDatabase.existingSecret }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.username }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.password }}
|
||||
{{- else if .Values.postgresql.auth.existingSecret }}
|
||||
name: {{ .Values.postgresql.auth.existingSecret }}
|
||||
key: postgres-password
|
||||
{{- else }}
|
||||
name: pixelfed-database
|
||||
key: password
|
||||
name: {{ .Values.postgresql.fullnameOverride }}
|
||||
key: postgres-password
|
||||
{{- end }}
|
||||
- name: DB_DATABASE
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
name: {{ .Values.externalDatabase.existingSecret }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.username }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.database }}
|
||||
{{- else }}
|
||||
name: pixelfed-database
|
||||
key: database
|
||||
value: postgres
|
||||
{{- end }}
|
||||
- name: DB_PORT
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.externalDatabase.existingSecret }}
|
||||
name: {{ .Values.externalDatabase.existingSecret }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.username }}
|
||||
key: {{ .Values.externalDatabase.existingSecretKeys.port }}
|
||||
{{- else }}
|
||||
name: pixelfed-database
|
||||
key: port
|
||||
value: {{ .Values.postgresql.primary.service.ports.postgresql | quote }}
|
||||
{{- end }}
|
||||
- name: DB_APPLY_NEW_MIGRATIONS_AUTOMATICALLY
|
||||
value: "{{ .Values.pixelfed.db_apply_new_migrations_automatically }}"
|
||||
|
||||
Reference in New Issue
Block a user