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