_sabnzbd.tpl 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. {{- define "sabnzbd.workload" -}}
  2. workload:
  3. sabnzbd:
  4. enabled: true
  5. primary: true
  6. type: Deployment
  7. podSpec:
  8. hostNetwork: {{ .Values.sabnzbdNetwork.hostNetwork }}
  9. containers:
  10. sabnzbd:
  11. enabled: true
  12. primary: true
  13. imageSelector: image
  14. securityContext:
  15. runAsUser: {{ .Values.sabnzbdRunAs.user }}
  16. runAsGroup: {{ .Values.sabnzbdRunAs.group }}
  17. env:
  18. SABNZBD__PORT: {{ .Values.sabnzbdNetwork.webPort }}
  19. {{ with .Values.sabnzbdConfig.additionalEnvs }}
  20. envList:
  21. {{ range $env := . }}
  22. - name: {{ $env.name }}
  23. value: {{ $env.value }}
  24. {{ end }}
  25. {{ end }}
  26. probes:
  27. liveness:
  28. enabled: true
  29. type: http
  30. port: "{{ .Values.sabnzbdNetwork.webPort }}"
  31. path: /api?mode=version
  32. readiness:
  33. enabled: true
  34. type: http
  35. port: "{{ .Values.sabnzbdNetwork.webPort }}"
  36. path: /api?mode=version
  37. startup:
  38. enabled: true
  39. type: http
  40. port: "{{ .Values.sabnzbdNetwork.webPort }}"
  41. path: /api?mode=version
  42. initContainers:
  43. {{- include "ix.v1.common.app.permissions" (dict "containerName" "01-permissions"
  44. "UID" .Values.sabnzbdRunAs.user
  45. "GID" .Values.sabnzbdRunAs.group
  46. "mode" "check"
  47. "type" "install") | nindent 8 }}
  48. {{- end -}}