_persistence.tpl 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. {{- define "planka.persistence" -}}
  2. persistence:
  3. avatars:
  4. enabled: true
  5. type: {{ .Values.plankaStorage.avatars.type }}
  6. datasetName: {{ .Values.plankaStorage.avatars.datasetName | default "" }}
  7. hostPath: {{ .Values.plankaStorage.avatars.hostPath | default "" }}
  8. targetSelector:
  9. planka:
  10. planka:
  11. mountPath: /app/public/user-avatars
  12. 01-permissions:
  13. mountPath: /mnt/directories/user-avatars
  14. bg-img:
  15. enabled: true
  16. type: {{ .Values.plankaStorage.backgroundImages.type }}
  17. datasetName: {{ .Values.plankaStorage.backgroundImages.datasetName | default "" }}
  18. hostPath: {{ .Values.plankaStorage.backgroundImages.hostPath | default "" }}
  19. targetSelector:
  20. planka:
  21. planka:
  22. mountPath: /app/public/project-background-images
  23. 01-permissions:
  24. mountPath: /mnt/directories/project-background-images
  25. attachments:
  26. enabled: true
  27. type: {{ .Values.plankaStorage.attachments.type }}
  28. datasetName: {{ .Values.plankaStorage.attachments.datasetName | default "" }}
  29. hostPath: {{ .Values.plankaStorage.attachments.hostPath | default "" }}
  30. targetSelector:
  31. planka:
  32. planka:
  33. mountPath: /app/private/attachments
  34. 01-permissions:
  35. mountPath: /mnt/directories/attachments
  36. tmp:
  37. enabled: true
  38. type: emptyDir
  39. targetSelector:
  40. planka:
  41. planka:
  42. mountPath: /tmp
  43. {{- range $idx, $storage := .Values.plankaStorage.additionalStorages }}
  44. {{ printf "planka-%v" (int $idx) }}:
  45. {{- $size := "" -}}
  46. {{- if $storage.size -}}
  47. {{- $size = (printf "%vGi" $storage.size) -}}
  48. {{- end }}
  49. enabled: true
  50. type: {{ $storage.type }}
  51. datasetName: {{ $storage.datasetName | default "" }}
  52. hostPath: {{ $storage.hostPath | default "" }}
  53. server: {{ $storage.server | default "" }}
  54. share: {{ $storage.share | default "" }}
  55. domain: {{ $storage.domain | default "" }}
  56. username: {{ $storage.username | default "" }}
  57. password: {{ $storage.password | default "" }}
  58. size: {{ $size }}
  59. {{- if eq $storage.type "smb-pv-pvc" }}
  60. mountOptions:
  61. - key: noperm
  62. {{- end }}
  63. targetSelector:
  64. planka:
  65. planka:
  66. mountPath: {{ $storage.mountPath }}
  67. 01-permissions:
  68. mountPath: /mnt/directories{{ $storage.mountPath }}
  69. {{- end }}
  70. {{- include "ix.v1.common.app.postgresPersistence"
  71. (dict "pgData" .Values.plankaStorage.pgData
  72. "pgBackup" .Values.plankaStorage.pgBackup
  73. ) | nindent 2 }}
  74. {{- end -}}