Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions charts/immich/templates/checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@
{{ if hasKey .Values "redis" }}
{{ fail "The redis subchart has been removed. Please see https://github.com/immich-app/immich-charts/releases/tag/immich-0.10.0 for more detail."}}
{{ end }}

{{- if and (ne .Values.immich.configurationKind "Secret") (ne .Values.immich.configurationKind "ConfigMap") }}
{{- fail "Invalid immich.configurationKind: must be either 'ConfigMap' or 'Secret'" }}
{{- end }}
7 changes: 6 additions & 1 deletion charts/immich/templates/immich-config.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- if .Values.immich.configuration }}
apiVersion: v1
kind: ConfigMap
kind: {{ .Values.immich.configurationKind }}
metadata:
name: {{ .Release.Name }}-immich-config
labels:
Expand All @@ -9,7 +9,12 @@ metadata:
app.kubernetes.io/name: {{ .Chart.Name }}
app.kubernetes.io/version: {{ .Chart.AppVersion }}
helm.sh/chart: {{ printf "%s-%s\n" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- if (eq .Values.immich.configurationKind "Secret")}}
type: Opaque
stringData:
{{- else }}
data:
{{- end }}
immich-config.yaml: |
{{- .Values.immich.configuration | toYaml | nindent 4 }}
{{- end }}
4 changes: 4 additions & 0 deletions charts/immich/templates/server.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,11 @@ persistence:
{{- if .Values.immich.configuration }}
config:
enabled: true
{{- if eq .Values.immich.configurationKind "Secret" }}
type: secret
{{- else }}
type: configMap
{{- end }}
name: {{ .Release.Name }}-immich-config
{{- end }}
data:
Expand Down
2 changes: 2 additions & 0 deletions charts/immich/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ immich:
# storageTemplate:
# enabled: true
# template: "{{y}}/{{y}}-{{MM}}-{{dd}}/{{filename}}"
# Sets the resource Kind to store configuration in. Must be either ConfigMap or Secret.
configurationKind: ConfigMap

# Dependencies

Expand Down
Loading