_immich-server.tpl 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. {{- define "immich.server.workload" -}}
  2. {{- $fullname := (include "ix.v1.common.lib.chart.names.fullname" $) -}}
  3. {{- $typesenseUrl := printf "http://%v-typesense:%v/health" $fullname .Values.immichNetwork.typesensePort }}
  4. workload:
  5. server:
  6. enabled: true
  7. primary: true
  8. type: Deployment
  9. podSpec:
  10. hostNetwork: false
  11. containers:
  12. server:
  13. enabled: true
  14. primary: true
  15. imageSelector: image
  16. securityContext:
  17. runAsUser: 0
  18. runAsGroup: 0
  19. runAsNonRoot: false
  20. readOnlyRootFilesystem: false
  21. args: start-server.sh
  22. envFrom:
  23. - secretRef:
  24. name: immich-creds
  25. - configMapRef:
  26. name: server-config
  27. probes:
  28. liveness:
  29. enabled: true
  30. type: http
  31. path: /server-info/ping
  32. port: {{ .Values.immichNetwork.serverPort }}
  33. readiness:
  34. enabled: true
  35. type: http
  36. path: /server-info/ping
  37. port: {{ .Values.immichNetwork.serverPort }}
  38. startup:
  39. enabled: true
  40. type: http
  41. path: /server-info/ping
  42. port: {{ .Values.immichNetwork.serverPort }}
  43. initContainers:
  44. {{- include "ix.v1.common.app.postgresWait" (dict "name" "postgres-wait"
  45. "secretName" "postgres-creds") | nindent 8 }}
  46. {{- include "ix.v1.common.app.redisWait" (dict "name" "redis-wait"
  47. "secretName" "redis-creds") | nindent 8 }}
  48. {{- if .Values.immichConfig.enableTypesense }}
  49. {{- include "immich.wait.init" (dict "url" $typesenseUrl) | indent 8 }}
  50. {{- end }}
  51. {{- end -}}